aboutsummaryrefslogtreecommitdiff
path: root/scripts/theme-studio/samples.py
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2026-07-02 13:35:28 -0400
committerCraig Jennings <c@cjennings.net>2026-07-02 13:35:28 -0400
commit9c7010ebe2041ae73195745d76403568237c2905 (patch)
treedf2bcd7c1d98645baf88ad227bd65ad4e0000d4b /scripts/theme-studio/samples.py
parent172c00e0a450309938bb4e87e612c715707ab1cf (diff)
downloaddotemacs-9c7010ebe2041ae73195745d76403568237c2905.tar.gz
dotemacs-9c7010ebe2041ae73195745d76403568237c2905.zip
feat(theme-studio): web-mode scene covering all 81 faces + HTML sample
The web-mode preview is one mixed document: markup with every tag/attr variant, an inline CSS part, a generic template block (engine-agnostic on purpose), and a script part carrying a JSON island, JSX depths, nested template literals, SQL-in-a-string, a PHP preprocessor island, and JSDoc annotations. The realism gate now covers it, so all 81 faces are exercised. SAMPLES gains an HTML language, which also enriches the syntax and auto-dim previews.
Diffstat (limited to 'scripts/theme-studio/samples.py')
-rw-r--r--scripts/theme-studio/samples.py18
1 files changed, 18 insertions, 0 deletions
diff --git a/scripts/theme-studio/samples.py b/scripts/theme-studio/samples.py
index feebd1b7..ca568ed3 100644
--- a/scripts/theme-studio/samples.py
+++ b/scripts/theme-studio/samples.py
@@ -704,6 +704,24 @@ ASMS=[
[('p',' '),('kw','xor'),('p',' '),('var','rdi'),('punc',','),('p',' '),('var','rdi'),('p',' '),('cmd',';'),('cm',' status 0')],
[('p',' '),('kw','syscall')],
]
+HTMLS=[
+ [('cm','<!doctype html>')],
+ [('cm','<!-- storefront page -->')],
+ [('punc','<'),('fnd','html'),('p',' '),('var','lang'),('op','='),('str','"en"'),('punc','>')],
+ [('punc','<'),('fnd','head'),('punc','>')],
+ [('p',' '),('punc','<'),('fnd','style'),('punc','>')],
+ [('p',' '),('pp','@media'),('p',' '),('punc','('),('prop','min-width'),('op',':'),('p',' '),('num','40rem'),('punc',')'),('p',' '),('punc','{')],
+ [('p',' '),('ty','body'),('p',' '),('fnc','.card'),('kw',':hover'),('p',' '),('punc','{'),('p',' '),('prop','color'),('op',':'),('p',' '),('con','#67809c'),('punc',';'),('p',' '),('punc','}}')],
+ [('p',' '),('punc','</'),('fnd','style'),('punc','>')],
+ [('punc','</'),('fnd','head'),('punc','>')],
+ [('punc','<'),('fnd','body'),('p',' '),('var','data-theme'),('op','='),('str','"dupre"'),('punc','>')],
+ [('p',' '),('punc','<'),('fnd','h1'),('punc','>'),('p','Fish '),('esc','&amp;'),('p',' Chips'),('punc','</'),('fnd','h1'),('punc','>')],
+ [('p',' '),('punc','<'),('fnd','script'),('punc','>')],
+ [('p',' '),('kw','const'),('p',' '),('var','total'),('p',' '),('op','='),('p',' '),('fnc','round'),('punc','('),('var','qty'),('p',' '),('op','*'),('p',' '),('var','price'),('punc',');'),('p',' '),('cmd','//'),('cm',' inline js')],
+ [('p',' '),('punc','</'),('fnd','script'),('punc','>')],
+ [('punc','</'),('fnd','body'),('punc','>')],
+ [('punc','</'),('fnd','html'),('punc','>')],
+]
# THEME_STUDIO_DATA_END: generate.py execs only the lines above this marker (the
# code samples and COLS). Everything below is the standalone /tmp/dupre-canon.html