From cef864a7be9abe6e53810a83f6a577e83433cc66 Mon Sep 17 00:00:00 2001 From: Hakim El Hattab Date: Fri, 8 Mar 2019 15:07:59 +0100 Subject: highlight plugin updates; support for line numbers and highlighting specific lines --- demo.html | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) (limited to 'demo.html') diff --git a/demo.html b/demo.html index b24ba18..ac273d5 100644 --- a/demo.html +++ b/demo.html @@ -199,16 +199,16 @@

Image Backgrounds

-
<section data-background="image.png">
+
<section data-background="image.png">

Tiled Backgrounds

-
<section data-background="image.png" data-background-repeat="repeat" data-background-size="100px">
+
<section data-background="image.png" data-background-repeat="repeat" data-background-size="100px">

Video Backgrounds

-
<section data-background-video="video.mp4,video.webm">
+
<section data-background-video="video.mp4,video.webm">
@@ -221,7 +221,7 @@

Different background transitions are available via the backgroundTransition option. This one's called "zoom".

-
Reveal.configure({ backgroundTransition: 'zoom' })
+
Reveal.configure({ backgroundTransition: 'zoom' })
@@ -229,25 +229,25 @@

You can override background transitions per-slide.

-
<section data-background-transition="zoom">
+
<section data-background-transition="zoom">

Pretty Code

-

-function linkify( selector ) {
-  if( supports3DTransforms ) {
-
-    var nodes = document.querySelectorAll( selector );
-
-    for( var i = 0, len = nodes.length; i < len; i++ ) {
-      var node = nodes[i];
-
-      if( !node.className ) {
-        node.className += ' roll';
-      }
-    }
-  }
+					

+import React, { useState } from 'react';
+
+function Example() {
+  const [count, setCount] = useState(0);
+
+  return (
+    <div>
+      <p>You clicked {count} times</p>
+      <button onClick={() => setCount(count + 1)}>
+        Click me
+      </button>
+    </div>
+  );
 }
 					

Code syntax highlighting courtesy of highlight.js.

-- cgit v1.2.3