JSFiddle - React, Tailwind, and code Playground
HTML
<script src="https://code.jquery.com/jquery-3.1.1.js"></script>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<body>
<div class="container">
<div id="boxes">
<!-- Step 1: Add the 'outlined' class to each of the boxes -->
<div id="box1" class="box"></div>
<div id="box2" class="box outlined"></div>
<div id="box3" class="box"></div>
</div>
<div id="toggles">
<h2>Toggles</h2>
<button class="btn" id="button_toggle_colors">Toggle Colors</button>
<button class="btn" id="button_toggle_roundedges">Toggle Rounded Borders</button>
<button class="btn" id="button_add_box">Add a New Box</button>
</div>
<div id="info">
<h2>Descriptions:</h2>
<ul>
<li><b>Toggle Colors</b>: Toggles the color on and off for each
box using CSS classes.</li>
<li><b>Toggle Rounded Borders</b>: Toggles the color on and off
for each box using CSS attributes.</li>
<li><b>Add a New Box</b>: Adds one new box to the container.</li>
</ul>
</div>
</div>
</body>
CSS
#boxes { margin-top: 50px; float: left; width: 100%; }
#toggles { float: left; width: 100%; margin-top: 10px; }
#info { float: left; margin-top: 5px; }
.box { width: 50px; height: 50px; float: left; }
.outlined { border: 2px solid black; }
.round-edge { border-radius: 15px; }
.teal { background-color: teal; }
JavaScript
/* INSTRUCTIONS
The buttons should have the effects described. You need to:
1. Add the outlined CSS class to each of the 3 boxes.
2. Modify the background-color CSS attribute on the boxes whenever
the Toggle Colors button is clicked.
3. Add/Remove the round-edge class on the boxes whenever the
Toggle Rounded Borders button is clicked.
4. Add a new box <div> whenever the Add new box button is clicked.
*/
var colorTeal = "rgb(57, 204, 204)";
$(document).ready(function() {
/* Step 2: Modifying CSS attributes with .css() */
/* Step 3: Using jQuery's .addClass()/.removeClass()/.toggleClass() */
/* Step 4: Adding new elements */
});