![]() ![]() ![]() The letters array has the list of letters and the last item is the empty string, this is for the empty tile. Update the index.html file as follows:įirst I got all the li items into a node list (something that is like an array) using the querySelectorAll. The tiles currently have contents that are defined in the html file, we will remove those contents and fill them in with JavaScript. index.html Sliding Tile Puzzle A B C D E F G H Īdd the following to the style sheet to style the empty tile: Before then, let’s give the list items contents, update index.html to have the following content (I’ve included the link for the Audiowide font) In the 8 tile sliding puzzle, the 9th tile should be empty so we will create a class that styles the empty tile.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |