Standardize GlitchComponent: glitch.json config, build/deploy setup, ignore node_modules
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -5,3 +5,4 @@ node_modules/
|
||||
npm-debug.log*
|
||||
yarn-debug.log*
|
||||
yarn-error.log*
|
||||
node_modules
|
||||
|
||||
@@ -19,5 +19,6 @@ From the workspace root, the standard wrappers also work:
|
||||
|
||||
- The packaged entrypoint is `src/index.tsx`
|
||||
- Dev-only styling lives in `src/dev-theme.css`
|
||||
- Host integration metadata lives in `glitch.manifest.json`
|
||||
- Release registration metadata lives in `glitch.json`
|
||||
- Compatibility manifest metadata lives in `glitch.manifest.json`
|
||||
- CDN release path: `/components/bloodsugar.js`
|
||||
|
||||
+60
@@ -0,0 +1,60 @@
|
||||
{
|
||||
"componentId": "bloodsugar",
|
||||
"displayName": "Blood Sugar Delay Lab",
|
||||
"description": "Blood Sugar Delay Lab glitch component for Glitch University",
|
||||
"version": "1.0.0",
|
||||
"entry": "dist/bloodsugar.js",
|
||||
"paramSchema": {
|
||||
"responseDelay": {
|
||||
"type": "range",
|
||||
"label": "Feedback Lag",
|
||||
"description": "Minutes of delay between glucose rising, insulin being secreted, and insulin action arriving.",
|
||||
"default": 34,
|
||||
"min": 0,
|
||||
"max": 80,
|
||||
"step": 1
|
||||
},
|
||||
"mealLoad": {
|
||||
"type": "range",
|
||||
"label": "Meal Size",
|
||||
"default": 44,
|
||||
"min": 20,
|
||||
"max": 80,
|
||||
"step": 1
|
||||
},
|
||||
"pancreasStrength": {
|
||||
"type": "range",
|
||||
"label": "Compensation Strength",
|
||||
"default": 1,
|
||||
"min": 0.45,
|
||||
"max": 1.6,
|
||||
"step": 0.01
|
||||
},
|
||||
"playbackSpeed": {
|
||||
"type": "range",
|
||||
"label": "Playback Speed",
|
||||
"default": 1,
|
||||
"min": 0.25,
|
||||
"max": 3,
|
||||
"step": 0.05
|
||||
},
|
||||
"primaryColor": {
|
||||
"type": "color",
|
||||
"label": "Glucose Color",
|
||||
"default": "#6366f1"
|
||||
},
|
||||
"accentColor": {
|
||||
"type": "color",
|
||||
"label": "Insulin Color",
|
||||
"default": "#22d3ee"
|
||||
}
|
||||
},
|
||||
"defaultParams": {
|
||||
"responseDelay": 34,
|
||||
"mealLoad": 44,
|
||||
"pancreasStrength": 1,
|
||||
"playbackSpeed": 1,
|
||||
"primaryColor": "#6366f1",
|
||||
"accentColor": "#22d3ee"
|
||||
}
|
||||
}
|
||||
@@ -9,7 +9,8 @@
|
||||
"tags": [
|
||||
"glitch-component",
|
||||
"biology",
|
||||
"systems",
|
||||
"feedback"
|
||||
"feedback-systems",
|
||||
"diabetes",
|
||||
"visualization"
|
||||
]
|
||||
}
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
"files": [
|
||||
"dist",
|
||||
"src/types.ts",
|
||||
"glitch.json",
|
||||
"glitch.manifest.json"
|
||||
],
|
||||
"scripts": {
|
||||
|
||||
+7
-2
@@ -1,5 +1,3 @@
|
||||
@import url("https://fonts.googleapis.com/css2?family=Iceland&family=JetBrains+Mono:wght@400;600&family=Russo+One&display=swap");
|
||||
|
||||
:root {
|
||||
--color-bg: #0a0a0f;
|
||||
--color-bg-secondary: #12121a;
|
||||
@@ -41,6 +39,13 @@ body {
|
||||
font-family: var(--font-main);
|
||||
}
|
||||
|
||||
button,
|
||||
input,
|
||||
select,
|
||||
textarea {
|
||||
font: inherit;
|
||||
}
|
||||
|
||||
.dev-shell {
|
||||
min-height: 100vh;
|
||||
padding: 1rem;
|
||||
|
||||
Reference in New Issue
Block a user