From 3d870234a6799df2d2832eec17fe0f1218b93037 Mon Sep 17 00:00:00 2001 From: Max Bo Date: Wed, 16 Oct 2024 13:36:30 +1100 Subject: [PATCH] Merge stylesheets --- index.html | 105 ++++++++++++++++++++----------------- stylesheets/echo.css | 32 ----------- stylesheets/observable.css | 15 ------ stylesheets/reflect.css | 15 ------ 4 files changed, 56 insertions(+), 111 deletions(-) delete mode 100644 stylesheets/echo.css delete mode 100644 stylesheets/observable.css delete mode 100644 stylesheets/reflect.css diff --git a/index.html b/index.html index afd2f34..64f536d 100644 --- a/index.html +++ b/index.html @@ -9,9 +9,7 @@ - - - + @@ -79,14 +77,14 @@

@celine/celine

@celine/celine wraps a subset of the Observable Notebook runtime to provide a minimal (and opinionated) API for reactive notebook construction using display: block, contenteditable <script> elements.

- It's also a followup to my article Reactive HTML notebooks (2024). I pondered calling it incel, short for inline cell, but was advised against it. + It's also a followup to my article Reactive HTML notebooks (2024). I considered calling it incel, short for inline cell, but was advised against it.

Installation

Add the following <script> element to your HTML file:

- -

Pick and choose some or all of these versioned stylesheets to add to your <head> block:

+ - +Consider LaTeX.css also.

API

+

The following <styles>s are marked contenteditable and reevaluate on edit.

+ +

.echo

+ +

The .echo class can display <script> and <style> elements inline, with a font with built-in syntax highlighting.

+ + + +

.reflect

+ +

The .reflect class forces <script> and <style> elements to display their opening and closing tags, type, class, id, and contenteditable attributes, (a little trick from This page is a truly naked, brutalist html quine).

+ + +

All of the following <script>s are marked contenteditable and reevaluate on blur.

celine.cell(name, [inputs, ]definition)

@@ -148,7 +159,7 @@

celine.cell(name, [inp

Ensure the <script>'s' id is the name parameterized to the cell constructor.

- - - - - - - -