Pen Settings



CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ add another resource


Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource


Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.


Auto Save

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.


<div class="tv">
  <div class="screen">
      <img id="ss" style="display:none" />
      <div id="form">
          <input type="text" placeholder="Code" id="code" />
          <input type="text" placeholder="Name" id="name" />

  <div class="btn one" onclick="">Next</div>
  <div class="btn two" onclick="internetclicker.previous()">Previous</div>

  <div class="power-button" onclick="setup()"></div>
  <p>Enter your name and code into the TV then click the red power button to connect. Enable screen sharing in your client app to see it displayed in the TV screen. Use the Next/Previous buttons to control your client machine.</p>
  <p>Open the console to see additional events being logged</p>



                html, body {
  height: 100%;

body {
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  justify-content: center;
  align-items: center;
  background: #164A41;

.tv {
  position: relative;
  flex: 0 0 auto;
  width: 469px;
  height: 314px;
  background: #5C5F58;
  border: 11px solid #591C0B;
  overflow: hidden;

.screen {
  top: 16px;
  left: 23px;
  position: relative;
  width: 311px;
  height: 266px;
  border-radius: 18px;
  background: #474747;
  border: 8px solid #262626;
  overflow: hidden;
  z-index: 1;
  opacity: 0;
  animation: assemble-screen 2s 0.5s forwards;

input[type="text"] {
  padding: 10px;
  border-radius: 10px;
  display: block;
  margin: 0 auto;
  margin-top: 20px;

#ss {
  /* display: none; */
  width: 100%;
  height: 100%;

.btn {
  position: absolute;
  border-radius: 10px;
  background: #591C0B;
  box-shadow: 0 1px #3d3d3d;
  color: black;
  font-weight: bolder;
  text-transform: uppercase;
  padding: 6px;
} {
      top: 31px;
      right: 28px;

  .btn.two {
      top: 88px;
      right: 8px;

.power-button {
  position: absolute;
  bottom: 27px;
  right: 50px;
  width: 20px;
  height: 20px;
  opacity: 1;
  border-radius: 35px;
  background: #ef5754;
  box-shadow: 0 1px #3d3d3d;
  transition: all 0.3s;

  .power-button:hover {
      box-shadow: 0 0;

@keyframes assemble-screen {
  0% {
      opacity: 0;

  100% {
      opacity: 1;



                var internetclicker;

function setup() {
  var code = document.getElementById("code").value,
    name = document.getElementById("name").value;

  internetclicker = new IC.Connection();

  internetclicker.on("speakerNotesChange", (payload) => console.log(payload));
  internetclicker.on("screenshotChange", (payload) => {
    document.getElementById("ss").src = payload.url;
  internetclicker.on("userStatusChange", (payload) => console.log(payload));
  internetclicker.on("connectError", (payload) => {
    alert("Could not connect: ", payload.message);
  internetclicker.on("connectSuccess", (payload) => {
    document.getElementById("form").style.display = "none";
    document.getElementById("ss").style.display = "initial";
  internetclicker.on("userRemoved", (payload) => console.log(payload));
  internetclicker.on("connectionStateChanged", (payload) =>
  internetclicker.on("clientStateChanged", (payload) => console.log(payload));
  internetclicker.on("timerStarted", (payload) => console.log(payload));
  internetclicker.on("timerStopped", (payload) => console.log(payload));
  internetclicker.on("timerPaused", (payload) => console.log(payload));

  internetclicker.start(code, name);

  internetclicker.on("userMessageReceived", (payload) => console.log(payload));