@f-ewald/components 1.44.0 → 1.45.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -0
- package/custom-elements.json +267 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/pixel-fire.d.ts +69 -0
- package/dist/pixel-fire.d.ts.map +1 -0
- package/dist/pixel-fire.js +296 -0
- package/dist/pixel-fire.js.map +1 -0
- package/docs/design-language.md +3 -3
- package/docs/pixel-fire.md +51 -0
- package/llms.txt +31 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -107,6 +107,7 @@ import "@f-ewald/components/roman-numeral.js";
|
|
|
107
107
|
| `<pagination-nav>` | [API reference](https://f-ewald.github.io/components/docs/pagination-nav.html) |
|
|
108
108
|
| `<percent-bar-chart>` | [API reference](https://f-ewald.github.io/components/docs/percent-bar-chart.html) |
|
|
109
109
|
| `<photo-gallery>` | [API reference](https://f-ewald.github.io/components/docs/photo-gallery.html) |
|
|
110
|
+
| `<pixel-fire>` | [API reference](https://f-ewald.github.io/components/docs/pixel-fire.html) |
|
|
110
111
|
| `<popover-panel>` | [API reference](https://f-ewald.github.io/components/docs/popover-panel.html) |
|
|
111
112
|
| `<price-history-chart>` | [API reference](https://f-ewald.github.io/components/docs/price-history-chart.html) |
|
|
112
113
|
| `<progress-bar>` | [API reference](https://f-ewald.github.io/components/docs/progress-bar.html) |
|
package/custom-elements.json
CHANGED
|
@@ -12390,6 +12390,14 @@
|
|
|
12390
12390
|
"module": "./tree-view.js"
|
|
12391
12391
|
}
|
|
12392
12392
|
},
|
|
12393
|
+
{
|
|
12394
|
+
"kind": "js",
|
|
12395
|
+
"name": "PixelFire",
|
|
12396
|
+
"declaration": {
|
|
12397
|
+
"name": "PixelFire",
|
|
12398
|
+
"module": "./pixel-fire.js"
|
|
12399
|
+
}
|
|
12400
|
+
},
|
|
12393
12401
|
{
|
|
12394
12402
|
"kind": "js",
|
|
12395
12403
|
"name": "PopoverPanel",
|
|
@@ -17884,6 +17892,265 @@
|
|
|
17884
17892
|
}
|
|
17885
17893
|
]
|
|
17886
17894
|
},
|
|
17895
|
+
{
|
|
17896
|
+
"kind": "javascript-module",
|
|
17897
|
+
"path": "src/pixel-fire.ts",
|
|
17898
|
+
"declarations": [
|
|
17899
|
+
{
|
|
17900
|
+
"kind": "class",
|
|
17901
|
+
"description": "Pixelated, 8-bit style fire in the manner of old computer games. By default\nit is pinned full width to the bottom of the viewport as a decorative,\nclick-through overlay; `contained` pins it to the bottom of the nearest\npositioned ancestor instead.\n\nThe strip's height is set with `--pixel-fire-height` (default `8rem`). It\npaints at `z-index: 30`, above ordinary page content but below `app-shell`'s\nchrome and every dialog or popover. Under `prefers-reduced-motion: reduce`\nit draws one still frame instead of animating. The canvas is hidden from\nassistive technology.",
|
|
17902
|
+
"name": "PixelFire",
|
|
17903
|
+
"members": [
|
|
17904
|
+
{
|
|
17905
|
+
"kind": "field",
|
|
17906
|
+
"name": "pixelSize",
|
|
17907
|
+
"type": {
|
|
17908
|
+
"text": "number"
|
|
17909
|
+
},
|
|
17910
|
+
"default": "4",
|
|
17911
|
+
"description": "Size of one fire pixel in CSS pixels; larger values look chunkier.",
|
|
17912
|
+
"attribute": "pixel-size"
|
|
17913
|
+
},
|
|
17914
|
+
{
|
|
17915
|
+
"kind": "field",
|
|
17916
|
+
"name": "intensity",
|
|
17917
|
+
"type": {
|
|
17918
|
+
"text": "number"
|
|
17919
|
+
},
|
|
17920
|
+
"default": "1",
|
|
17921
|
+
"description": "Heat of the fire's source, from `0` to `1`. Lowering it shortens the\nflames; `0` lets the fire burn out.",
|
|
17922
|
+
"attribute": "intensity"
|
|
17923
|
+
},
|
|
17924
|
+
{
|
|
17925
|
+
"kind": "field",
|
|
17926
|
+
"name": "contained",
|
|
17927
|
+
"type": {
|
|
17928
|
+
"text": "boolean"
|
|
17929
|
+
},
|
|
17930
|
+
"default": "false",
|
|
17931
|
+
"description": "Pins the fire to the bottom of the nearest positioned ancestor instead of\nthe viewport.",
|
|
17932
|
+
"attribute": "contained",
|
|
17933
|
+
"reflects": true
|
|
17934
|
+
},
|
|
17935
|
+
{
|
|
17936
|
+
"kind": "field",
|
|
17937
|
+
"name": "_cols",
|
|
17938
|
+
"type": {
|
|
17939
|
+
"text": "number"
|
|
17940
|
+
},
|
|
17941
|
+
"privacy": "private",
|
|
17942
|
+
"default": "0"
|
|
17943
|
+
},
|
|
17944
|
+
{
|
|
17945
|
+
"kind": "field",
|
|
17946
|
+
"name": "_rows",
|
|
17947
|
+
"type": {
|
|
17948
|
+
"text": "number"
|
|
17949
|
+
},
|
|
17950
|
+
"privacy": "private",
|
|
17951
|
+
"default": "0"
|
|
17952
|
+
},
|
|
17953
|
+
{
|
|
17954
|
+
"kind": "field",
|
|
17955
|
+
"name": "_heat",
|
|
17956
|
+
"privacy": "private",
|
|
17957
|
+
"default": "new Float32Array(0)"
|
|
17958
|
+
},
|
|
17959
|
+
{
|
|
17960
|
+
"kind": "field",
|
|
17961
|
+
"name": "_cooling",
|
|
17962
|
+
"type": {
|
|
17963
|
+
"text": "Float32Array"
|
|
17964
|
+
},
|
|
17965
|
+
"privacy": "private",
|
|
17966
|
+
"default": "new Float32Array(0)"
|
|
17967
|
+
},
|
|
17968
|
+
{
|
|
17969
|
+
"kind": "field",
|
|
17970
|
+
"name": "_time",
|
|
17971
|
+
"type": {
|
|
17972
|
+
"text": "number"
|
|
17973
|
+
},
|
|
17974
|
+
"privacy": "private",
|
|
17975
|
+
"default": "0"
|
|
17976
|
+
},
|
|
17977
|
+
{
|
|
17978
|
+
"kind": "field",
|
|
17979
|
+
"name": "_image",
|
|
17980
|
+
"type": {
|
|
17981
|
+
"text": "ImageData | undefined"
|
|
17982
|
+
},
|
|
17983
|
+
"privacy": "private"
|
|
17984
|
+
},
|
|
17985
|
+
{
|
|
17986
|
+
"kind": "field",
|
|
17987
|
+
"name": "_frame",
|
|
17988
|
+
"type": {
|
|
17989
|
+
"text": "number | undefined"
|
|
17990
|
+
},
|
|
17991
|
+
"privacy": "private"
|
|
17992
|
+
},
|
|
17993
|
+
{
|
|
17994
|
+
"kind": "field",
|
|
17995
|
+
"name": "_lastStep",
|
|
17996
|
+
"type": {
|
|
17997
|
+
"text": "number"
|
|
17998
|
+
},
|
|
17999
|
+
"privacy": "private",
|
|
18000
|
+
"default": "0"
|
|
18001
|
+
},
|
|
18002
|
+
{
|
|
18003
|
+
"kind": "field",
|
|
18004
|
+
"name": "_resizeObserver",
|
|
18005
|
+
"type": {
|
|
18006
|
+
"text": "ResizeObserver | undefined"
|
|
18007
|
+
},
|
|
18008
|
+
"privacy": "private"
|
|
18009
|
+
},
|
|
18010
|
+
{
|
|
18011
|
+
"kind": "field",
|
|
18012
|
+
"name": "_motionQuery",
|
|
18013
|
+
"type": {
|
|
18014
|
+
"text": "MediaQueryList | undefined"
|
|
18015
|
+
},
|
|
18016
|
+
"privacy": "private"
|
|
18017
|
+
},
|
|
18018
|
+
{
|
|
18019
|
+
"kind": "field",
|
|
18020
|
+
"name": "_canvas",
|
|
18021
|
+
"type": {
|
|
18022
|
+
"text": "HTMLCanvasElement | null"
|
|
18023
|
+
},
|
|
18024
|
+
"privacy": "private",
|
|
18025
|
+
"readonly": true
|
|
18026
|
+
},
|
|
18027
|
+
{
|
|
18028
|
+
"kind": "field",
|
|
18029
|
+
"name": "_cellSize",
|
|
18030
|
+
"type": {
|
|
18031
|
+
"text": "number"
|
|
18032
|
+
},
|
|
18033
|
+
"privacy": "private",
|
|
18034
|
+
"readonly": true
|
|
18035
|
+
},
|
|
18036
|
+
{
|
|
18037
|
+
"kind": "field",
|
|
18038
|
+
"name": "_sourceHeat",
|
|
18039
|
+
"type": {
|
|
18040
|
+
"text": "number"
|
|
18041
|
+
},
|
|
18042
|
+
"privacy": "private",
|
|
18043
|
+
"readonly": true
|
|
18044
|
+
},
|
|
18045
|
+
{
|
|
18046
|
+
"kind": "field",
|
|
18047
|
+
"name": "_resize",
|
|
18048
|
+
"privacy": "private",
|
|
18049
|
+
"readonly": true,
|
|
18050
|
+
"description": "Rebuilds the fire grid to cover the host's current box, then restarts it."
|
|
18051
|
+
},
|
|
18052
|
+
{
|
|
18053
|
+
"kind": "field",
|
|
18054
|
+
"name": "_restart",
|
|
18055
|
+
"privacy": "private",
|
|
18056
|
+
"readonly": true,
|
|
18057
|
+
"description": "Animates the fire, or draws one settled frame under reduced motion."
|
|
18058
|
+
},
|
|
18059
|
+
{
|
|
18060
|
+
"kind": "method",
|
|
18061
|
+
"name": "_stop",
|
|
18062
|
+
"privacy": "private",
|
|
18063
|
+
"return": {
|
|
18064
|
+
"type": {
|
|
18065
|
+
"text": "void"
|
|
18066
|
+
}
|
|
18067
|
+
}
|
|
18068
|
+
},
|
|
18069
|
+
{
|
|
18070
|
+
"kind": "field",
|
|
18071
|
+
"name": "_tick",
|
|
18072
|
+
"privacy": "private",
|
|
18073
|
+
"readonly": true
|
|
18074
|
+
},
|
|
18075
|
+
{
|
|
18076
|
+
"kind": "method",
|
|
18077
|
+
"name": "_step",
|
|
18078
|
+
"privacy": "private",
|
|
18079
|
+
"return": {
|
|
18080
|
+
"type": {
|
|
18081
|
+
"text": ""
|
|
18082
|
+
}
|
|
18083
|
+
},
|
|
18084
|
+
"description": "Advances the fire one step: the bottom row is fed with heat and every cell\nrises one row, drifting sideways and cooling at random."
|
|
18085
|
+
},
|
|
18086
|
+
{
|
|
18087
|
+
"kind": "method",
|
|
18088
|
+
"name": "_draw",
|
|
18089
|
+
"privacy": "private",
|
|
18090
|
+
"return": {
|
|
18091
|
+
"type": {
|
|
18092
|
+
"text": "void"
|
|
18093
|
+
}
|
|
18094
|
+
},
|
|
18095
|
+
"description": "Paints the heat grid to the canvas through the palette."
|
|
18096
|
+
}
|
|
18097
|
+
],
|
|
18098
|
+
"attributes": [
|
|
18099
|
+
{
|
|
18100
|
+
"name": "pixel-size",
|
|
18101
|
+
"type": {
|
|
18102
|
+
"text": "number"
|
|
18103
|
+
},
|
|
18104
|
+
"default": "4",
|
|
18105
|
+
"description": "Size of one fire pixel in CSS pixels; larger values look chunkier.",
|
|
18106
|
+
"fieldName": "pixelSize"
|
|
18107
|
+
},
|
|
18108
|
+
{
|
|
18109
|
+
"name": "intensity",
|
|
18110
|
+
"type": {
|
|
18111
|
+
"text": "number"
|
|
18112
|
+
},
|
|
18113
|
+
"default": "1",
|
|
18114
|
+
"description": "Heat of the fire's source, from `0` to `1`. Lowering it shortens the\nflames; `0` lets the fire burn out.",
|
|
18115
|
+
"fieldName": "intensity"
|
|
18116
|
+
},
|
|
18117
|
+
{
|
|
18118
|
+
"name": "contained",
|
|
18119
|
+
"type": {
|
|
18120
|
+
"text": "boolean"
|
|
18121
|
+
},
|
|
18122
|
+
"default": "false",
|
|
18123
|
+
"description": "Pins the fire to the bottom of the nearest positioned ancestor instead of\nthe viewport.",
|
|
18124
|
+
"fieldName": "contained"
|
|
18125
|
+
}
|
|
18126
|
+
],
|
|
18127
|
+
"superclass": {
|
|
18128
|
+
"name": "LitElement",
|
|
18129
|
+
"package": "lit"
|
|
18130
|
+
},
|
|
18131
|
+
"tagName": "pixel-fire",
|
|
18132
|
+
"customElement": true
|
|
18133
|
+
}
|
|
18134
|
+
],
|
|
18135
|
+
"exports": [
|
|
18136
|
+
{
|
|
18137
|
+
"kind": "js",
|
|
18138
|
+
"name": "PixelFire",
|
|
18139
|
+
"declaration": {
|
|
18140
|
+
"name": "PixelFire",
|
|
18141
|
+
"module": "src/pixel-fire.ts"
|
|
18142
|
+
}
|
|
18143
|
+
},
|
|
18144
|
+
{
|
|
18145
|
+
"kind": "custom-element-definition",
|
|
18146
|
+
"name": "pixel-fire",
|
|
18147
|
+
"declaration": {
|
|
18148
|
+
"name": "PixelFire",
|
|
18149
|
+
"module": "src/pixel-fire.ts"
|
|
18150
|
+
}
|
|
18151
|
+
}
|
|
18152
|
+
]
|
|
18153
|
+
},
|
|
17887
18154
|
{
|
|
17888
18155
|
"kind": "javascript-module",
|
|
17889
18156
|
"path": "src/popover-panel.ts",
|
package/dist/index.d.ts
CHANGED
|
@@ -56,6 +56,7 @@ export { MultiSelect, type MultiSelectOption, type MultiSelectVariant, } from ".
|
|
|
56
56
|
export { DataTable, type DataTableAlign, type DataTableColumn } from "./data-table.js";
|
|
57
57
|
export { TileGrid } from "./tile-grid.js";
|
|
58
58
|
export { TreeView, type TreeNode } from "./tree-view.js";
|
|
59
|
+
export { PixelFire } from "./pixel-fire.js";
|
|
59
60
|
export { PopoverPanel } from "./popover-panel.js";
|
|
60
61
|
export { DropdownButton, type DropdownButtonVariant, type DropdownOption, } from "./dropdown-button.js";
|
|
61
62
|
export { IconButton } from "./icon-button.js";
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAC/D,OAAO,EACL,YAAY,EACZ,KAAK,wBAAwB,EAC7B,KAAK,qBAAqB,EAC1B,KAAK,6BAA6B,GACnC,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AACpD,OAAO,EAAE,WAAW,EAAE,KAAK,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACtE,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,EACL,iBAAiB,EACjB,aAAa,EACb,WAAW,EACX,UAAU,EACV,aAAa,EACb,KAAK,YAAY,GAClB,MAAM,yBAAyB,CAAC;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oBAAoB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -56,6 +56,7 @@ export { MultiSelect, } from "./multi-select.js";
|
|
|
56
56
|
export { DataTable } from "./data-table.js";
|
|
57
57
|
export { TileGrid } from "./tile-grid.js";
|
|
58
58
|
export { TreeView } from "./tree-view.js";
|
|
59
|
+
export { PixelFire } from "./pixel-fire.js";
|
|
59
60
|
export { PopoverPanel } from "./popover-panel.js";
|
|
60
61
|
export { DropdownButton, } from "./dropdown-button.js";
|
|
61
62
|
export { IconButton } from "./icon-button.js";
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAC/D,OAAO,EACL,YAAY,GAIb,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AACpD,OAAO,EAAE,WAAW,EAAwB,MAAM,mBAAmB,CAAC;AACtE,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,EACL,iBAAiB,EACjB,aAAa,EACb,WAAW,EACX,UAAU,EACV,aAAa,GAEd,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EACL,UAAU,GAIX,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAA+B,MAAM,wBAAwB,CAAC;AACvF,OAAO,EAAE,QAA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,CAAC;AAC7B,OAAO,EAAE,QAAQ,EAA4C,MAAM,gBAAgB,CAAC;AACpF,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC","sourcesContent":["export { AnimateConfetti } from \"./animate-confetti.js\";\nexport { GalleryItem } from \"./gallery-item.js\";\nexport { GalleryItemVariant } from \"./gallery-item-variant.js\";\nexport {\n PhotoGallery,\n type PhotoGalleryChangeReason,\n type PhotoGalleryObjectFit,\n type PhotoGallerySlideChangeDetail,\n} from \"./photo-gallery.js\";\nexport { RevealButton } from \"./reveal-button.js\";\nexport { RomanNumeral } from \"./roman-numeral.js\";\nexport { ConfirmDialog } from \"./confirm-dialog.js\";\nexport { ModalDialog, type ModalDialogSize } from \"./modal-dialog.js\";\nexport { ContentDivider } from \"./content-divider.js\";\nexport {\n ToastNotification,\n notifySuccess,\n notifyError,\n notifyInfo,\n notifyWarning,\n type ToastVariant,\n} from \"./toast-notification.js\";\nexport { ScrollToBottom } from \"./scroll-to-bottom.js\";\nexport {\n ScrollDots,\n type DotSelectDetail,\n type ScrollDotItem,\n type ScrollDotsItem,\n} from \"./scroll-dots.js\";\nexport { ScrollToTop } from \"./scroll-to-top.js\";\nexport { FullscreenButton, type FullscreenChangeDetail } from \"./fullscreen-button.js\";\nexport { SkipLink } from \"./skip-link.js\";\nexport { SlidePanel } from \"./slide-panel.js\";\nexport { CopyLinkButton } from \"./copy-link-button.js\";\nexport { RelativeTime } from \"./relative-time.js\";\nexport { DistanceValue } from \"./distance-value.js\";\nexport { PriceHistoryChart, type PricePoint } from \"./price-history-chart.js\";\nexport { DistributionChart, type DistributionValue } from \"./distribution-chart.js\";\nexport { PercentBarChart, type PercentBarGroup } from \"./percent-bar-chart.js\";\nexport { WeightBarChart, type WeightBarItem } from \"./weight-bar-chart.js\";\nexport {\n DagGraph,\n type DagControl,\n type DagDirection,\n type DagDirectionChangeDetail,\n type DagEdge,\n type DagNode,\n type DagNodeKind,\n type DagNodeSelectDetail,\n} from \"./dag-graph.js\";\nexport {\n AddressAutocomplete,\n type AddressSuggestion,\n} from \"./address-autocomplete.js\";\nexport {\n AutocompleteInput,\n type AutocompleteOption,\n} from \"./autocomplete-input.js\";\nexport { UserAvatar } from \"./user-avatar.js\";\nexport { MapPin } from \"./map-pin.js\";\nexport { MapCircle } from \"./map-circle.js\";\nexport { MapboxMap } from \"./mapbox-map.js\";\nexport { RadioCards, type RadioCardOption } from \"./radio-cards.js\";\nexport { RadioPills, type RadioPillOption } from \"./radio-pills.js\";\nexport { RangeSlider } from \"./range-slider.js\";\nexport { BreadcrumbNav, type BreadcrumbItem, type BreadcrumbNavigateDetail } from \"./breadcrumb-nav.js\";\nexport { ButtonGroup, type ButtonGroupOption } from \"./button-group.js\";\nexport { UiButton, type ButtonVariant } from \"./ui-button.js\";\nexport { StatMeter } from \"./stat-meter.js\";\nexport { ProgressBar } from \"./progress-bar.js\";\nexport { StatusBanner, type StatusBannerVariant } from \"./status-banner.js\";\nexport { UiAdmonition, type AdmonitionVariant } from \"./ui-admonition.js\";\nexport { StatusPill, type StatusPillColor } from \"./status-pill.js\";\nexport { EditableText } from \"./editable-text.js\";\nexport { EmptyState } from \"./empty-state.js\";\nexport { LiveTimer } from \"./live-timer.js\";\nexport { CountdownTimer } from \"./countdown-timer.js\";\nexport { LoadMore } from \"./load-more.js\";\nexport { LoadingSpinner } from \"./loading-spinner.js\";\nexport { LoadingDots } from \"./loading-dots.js\";\nexport {\n ChatMessage,\n type ChatMessageRole,\n type ChatMessageVariant,\n} from \"./chat-message.js\";\nexport { ChevronPanel } from \"./chevron-panel.js\";\nexport { UiCheckbox } from \"./ui-checkbox.js\";\nexport { UiTooltip, type UiTooltipPlacement } from \"./ui-tooltip.js\";\nexport { FormField } from \"./form-field.js\";\nexport { FormSelect, type SelectOption } from \"./form-select.js\";\nexport {\n MultiSelect,\n type MultiSelectOption,\n type MultiSelectVariant,\n} from \"./multi-select.js\";\nexport { DataTable, type DataTableAlign, type DataTableColumn } from \"./data-table.js\";\nexport { TileGrid } from \"./tile-grid.js\";\nexport { TreeView, type TreeNode } from \"./tree-view.js\";\nexport { PopoverPanel } from \"./popover-panel.js\";\nexport {\n DropdownButton,\n type DropdownButtonVariant,\n type DropdownOption,\n} from \"./dropdown-button.js\";\nexport { IconButton } from \"./icon-button.js\";\nexport { KbdHint, type KbdPlatform } from \"./kbd-hint.js\";\nexport { KindIcon, type KindIconStyle } from \"./kind-icon.js\";\nexport { FrameBox } from \"./frame-box.js\";\nexport { AppShell, type SidebarToggleDetail } from \"./app-shell.js\";\nexport { AppSidebar } from \"./app-sidebar.js\";\nexport { ActionBar } from \"./action-bar.js\";\nexport { PageHeader } from \"./page-header.js\";\nexport { PaginationNav, type PageChangeDetail } from \"./pagination-nav.js\";\nexport { FormActions } from \"./form-actions.js\";\nexport { TimelineContainer, type TimelineLayout } from \"./timeline-container.js\";\nexport { TimelineEntry } from \"./timeline-entry.js\";\nexport { CalendarDay } from \"./calendar-day.js\";\nexport { CalendarEntry } from \"./calendar-entry.js\";\nexport { CalendarMonth } from \"./calendar-month.js\";\nexport { CalendarWeek } from \"./calendar-week.js\";\nexport { CalendarYear } from \"./calendar-year.js\";\nexport {\n KanbanBoard,\n type KanbanCardData,\n type KanbanColumnData,\n type KanbanCardMoveDetail,\n type KanbanCardOpenDetail,\n} from \"./kanban-board.js\";\nexport { KanbanColumn } from \"./kanban-column.js\";\nexport { KanbanCard } from \"./kanban-card.js\";\nexport { TextArea } from \"./text-area.js\";\nexport { LinkCard, type LinkCardStatus } from \"./link-card.js\";\nexport { CardGrid } from \"./card-grid.js\";\nexport { MarkdownView } from \"./markdown-view.js\";\nexport { AutoScroll } from \"./auto-scroll.js\";\nexport { SpecList, type SpecListItem } from \"./spec-list.js\";\nexport { SplitHero } from \"./split-hero.js\";\nexport { TabBar, type TabChangeDetail } from \"./tab-bar.js\";\nexport { TabItem } from \"./tab-item.js\";\nexport { MarkdownEditor } from \"./markdown-editor.js\";\nexport {\n parseFrontMatter,\n formatFrontMatterValue,\n type FrontMatterResult,\n} from \"./utils/front-matter.js\";\nexport {\n formatDuration,\n formatClockDuration,\n type DurationFormat,\n} from \"./utils/duration.js\";\nexport { AudioPlayer } from \"./audio-player.js\";\nexport { VideoPlayer } from \"./video-player.js\";\nexport { VoteControl } from \"./vote-control.js\";\nexport { CommentComposer } from \"./comment-composer.js\";\nexport { CronSchedule } from \"./cron-schedule.js\";\nexport {\n CRON_ALIASES,\n CRON_FIELD_BOUNDS,\n CRON_FIELD_LABELS,\n CRON_FIELD_NAMES,\n MONTH_ABBREVIATIONS,\n MONTH_NAMES,\n WEEKDAY_ABBREVIATIONS,\n WEEKDAY_NAMES,\n describeCron,\n detectFrequency,\n expandField,\n fieldFromValues,\n formatCron,\n isEveryValue,\n parseCron,\n type CronExpression,\n type CronField,\n type CronFieldName,\n type CronFrequency,\n type CronTerm,\n} from \"./utils/cron.js\";\nexport {\n tokens,\n tokenValues,\n darkTokenValues,\n gradientTokenValues,\n metroTokenValues,\n blueprintTokenValues,\n developerDarkTokenValues,\n developerLightTokenValues,\n} from \"./tokens.js\";\nexport * from \"./icons.js\";\nexport { BlinkCursor } from \"./blink-cursor.js\";\nexport { CommentLabel } from \"./comment-label.js\";\nexport { StatStrip, type StatStripItem } from \"./stat-strip.js\";\nexport { StepLadder, type StepLadderItem } from \"./step-ladder.js\";\nexport {\n TerminalBlock,\n type TerminalLine,\n type TerminalLineType,\n} from \"./terminal-block.js\";\nexport { CodeDiff, type CodeDiffLine, type CodeDiffLineType } from \"./code-diff.js\";\nexport { WindowChrome } from \"./window-chrome.js\";\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAC/D,OAAO,EACL,YAAY,GAIb,M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oBAAoB,CAAC;AAClD,OAAO,EACL,YAAY,EACZ,iBAAiB,EACjB,iBAAiB,EACjB,gBAAgB,EAChB,mBAAmB,EACnB,WAAW,EACX,qBAAqB,EACrB,aAAa,EACb,YAAY,EACZ,eAAe,EACf,WAAW,EACX,eAAe,EACf,UAAU,EACV,YAAY,EACZ,SAAS,GAMV,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACL,MAAM,EACN,WAAW,EACX,eAAe,EACf,mBAAmB,EACnB,gBAAgB,EAChB,oBAAoB,EACpB,wBAAwB,EACxB,yBAAyB,GAC1B,MAAM,aAAa,CAAC;AACrB,cAAc,YAAY,CAAC;AAC3B,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,SAAS,EAAsB,MAAM,iBAAiB,CAAC;AAChE,OAAO,EAAE,UAAU,EAAuB,MAAM,kBAAkB,CAAC;AACnE,OAAO,EACL,aAAa,GAGd,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,QAAQ,EAA4C,MAAM,gBAAgB,CAAC;AACpF,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC","sourcesContent":["export { AnimateConfetti } from \"./animate-confetti.js\";\nexport { GalleryItem } from \"./gallery-item.js\";\nexport { GalleryItemVariant } from \"./gallery-item-variant.js\";\nexport {\n PhotoGallery,\n type PhotoGalleryChangeReason,\n type PhotoGalleryObjectFit,\n type PhotoGallerySlideChangeDetail,\n} from \"./photo-gallery.js\";\nexport { RevealButton } from \"./reveal-button.js\";\nexport { RomanNumeral } from \"./roman-numeral.js\";\nexport { ConfirmDialog } from \"./confirm-dialog.js\";\nexport { ModalDialog, type ModalDialogSize } from \"./modal-dialog.js\";\nexport { ContentDivider } from \"./content-divider.js\";\nexport {\n ToastNotification,\n notifySuccess,\n notifyError,\n notifyInfo,\n notifyWarning,\n type ToastVariant,\n} from \"./toast-notification.js\";\nexport { ScrollToBottom } from \"./scroll-to-bottom.js\";\nexport {\n ScrollDots,\n type DotSelectDetail,\n type ScrollDotItem,\n type ScrollDotsItem,\n} from \"./scroll-dots.js\";\nexport { ScrollToTop } from \"./scroll-to-top.js\";\nexport { FullscreenButton, type FullscreenChangeDetail } from \"./fullscreen-button.js\";\nexport { SkipLink } from \"./skip-link.js\";\nexport { SlidePanel } from \"./slide-panel.js\";\nexport { CopyLinkButton } from \"./copy-link-button.js\";\nexport { RelativeTime } from \"./relative-time.js\";\nexport { DistanceValue } from \"./distance-value.js\";\nexport { PriceHistoryChart, type PricePoint } from \"./price-history-chart.js\";\nexport { DistributionChart, type DistributionValue } from \"./distribution-chart.js\";\nexport { PercentBarChart, type PercentBarGroup } from \"./percent-bar-chart.js\";\nexport { WeightBarChart, type WeightBarItem } from \"./weight-bar-chart.js\";\nexport {\n DagGraph,\n type DagControl,\n type DagDirection,\n type DagDirectionChangeDetail,\n type DagEdge,\n type DagNode,\n type DagNodeKind,\n type DagNodeSelectDetail,\n} from \"./dag-graph.js\";\nexport {\n AddressAutocomplete,\n type AddressSuggestion,\n} from \"./address-autocomplete.js\";\nexport {\n AutocompleteInput,\n type AutocompleteOption,\n} from \"./autocomplete-input.js\";\nexport { UserAvatar } from \"./user-avatar.js\";\nexport { MapPin } from \"./map-pin.js\";\nexport { MapCircle } from \"./map-circle.js\";\nexport { MapboxMap } from \"./mapbox-map.js\";\nexport { RadioCards, type RadioCardOption } from \"./radio-cards.js\";\nexport { RadioPills, type RadioPillOption } from \"./radio-pills.js\";\nexport { RangeSlider } from \"./range-slider.js\";\nexport { BreadcrumbNav, type BreadcrumbItem, type BreadcrumbNavigateDetail } from \"./breadcrumb-nav.js\";\nexport { ButtonGroup, type ButtonGroupOption } from \"./button-group.js\";\nexport { UiButton, type ButtonVariant } from \"./ui-button.js\";\nexport { StatMeter } from \"./stat-meter.js\";\nexport { ProgressBar } from \"./progress-bar.js\";\nexport { StatusBanner, type StatusBannerVariant } from \"./status-banner.js\";\nexport { UiAdmonition, type AdmonitionVariant } from \"./ui-admonition.js\";\nexport { StatusPill, type StatusPillColor } from \"./status-pill.js\";\nexport { EditableText } from \"./editable-text.js\";\nexport { EmptyState } from \"./empty-state.js\";\nexport { LiveTimer } from \"./live-timer.js\";\nexport { CountdownTimer } from \"./countdown-timer.js\";\nexport { LoadMore } from \"./load-more.js\";\nexport { LoadingSpinner } from \"./loading-spinner.js\";\nexport { LoadingDots } from \"./loading-dots.js\";\nexport {\n ChatMessage,\n type ChatMessageRole,\n type ChatMessageVariant,\n} from \"./chat-message.js\";\nexport { ChevronPanel } from \"./chevron-panel.js\";\nexport { UiCheckbox } from \"./ui-checkbox.js\";\nexport { UiTooltip, type UiTooltipPlacement } from \"./ui-tooltip.js\";\nexport { FormField } from \"./form-field.js\";\nexport { FormSelect, type SelectOption } from \"./form-select.js\";\nexport {\n MultiSelect,\n type MultiSelectOption,\n type MultiSelectVariant,\n} from \"./multi-select.js\";\nexport { DataTable, type DataTableAlign, type DataTableColumn } from \"./data-table.js\";\nexport { TileGrid } from \"./tile-grid.js\";\nexport { TreeView, type TreeNode } from \"./tree-view.js\";\nexport { PixelFire } from \"./pixel-fire.js\";\nexport { PopoverPanel } from \"./popover-panel.js\";\nexport {\n DropdownButton,\n type DropdownButtonVariant,\n type DropdownOption,\n} from \"./dropdown-button.js\";\nexport { IconButton } from \"./icon-button.js\";\nexport { KbdHint, type KbdPlatform } from \"./kbd-hint.js\";\nexport { KindIcon, type KindIconStyle } from \"./kind-icon.js\";\nexport { FrameBox } from \"./frame-box.js\";\nexport { AppShell, type SidebarToggleDetail } from \"./app-shell.js\";\nexport { AppSidebar } from \"./app-sidebar.js\";\nexport { ActionBar } from \"./action-bar.js\";\nexport { PageHeader } from \"./page-header.js\";\nexport { PaginationNav, type PageChangeDetail } from \"./pagination-nav.js\";\nexport { FormActions } from \"./form-actions.js\";\nexport { TimelineContainer, type TimelineLayout } from \"./timeline-container.js\";\nexport { TimelineEntry } from \"./timeline-entry.js\";\nexport { CalendarDay } from \"./calendar-day.js\";\nexport { CalendarEntry } from \"./calendar-entry.js\";\nexport { CalendarMonth } from \"./calendar-month.js\";\nexport { CalendarWeek } from \"./calendar-week.js\";\nexport { CalendarYear } from \"./calendar-year.js\";\nexport {\n KanbanBoard,\n type KanbanCardData,\n type KanbanColumnData,\n type KanbanCardMoveDetail,\n type KanbanCardOpenDetail,\n} from \"./kanban-board.js\";\nexport { KanbanColumn } from \"./kanban-column.js\";\nexport { KanbanCard } from \"./kanban-card.js\";\nexport { TextArea } from \"./text-area.js\";\nexport { LinkCard, type LinkCardStatus } from \"./link-card.js\";\nexport { CardGrid } from \"./card-grid.js\";\nexport { MarkdownView } from \"./markdown-view.js\";\nexport { AutoScroll } from \"./auto-scroll.js\";\nexport { SpecList, type SpecListItem } from \"./spec-list.js\";\nexport { SplitHero } from \"./split-hero.js\";\nexport { TabBar, type TabChangeDetail } from \"./tab-bar.js\";\nexport { TabItem } from \"./tab-item.js\";\nexport { MarkdownEditor } from \"./markdown-editor.js\";\nexport {\n parseFrontMatter,\n formatFrontMatterValue,\n type FrontMatterResult,\n} from \"./utils/front-matter.js\";\nexport {\n formatDuration,\n formatClockDuration,\n type DurationFormat,\n} from \"./utils/duration.js\";\nexport { AudioPlayer } from \"./audio-player.js\";\nexport { VideoPlayer } from \"./video-player.js\";\nexport { VoteControl } from \"./vote-control.js\";\nexport { CommentComposer } from \"./comment-composer.js\";\nexport { CronSchedule } from \"./cron-schedule.js\";\nexport {\n CRON_ALIASES,\n CRON_FIELD_BOUNDS,\n CRON_FIELD_LABELS,\n CRON_FIELD_NAMES,\n MONTH_ABBREVIATIONS,\n MONTH_NAMES,\n WEEKDAY_ABBREVIATIONS,\n WEEKDAY_NAMES,\n describeCron,\n detectFrequency,\n expandField,\n fieldFromValues,\n formatCron,\n isEveryValue,\n parseCron,\n type CronExpression,\n type CronField,\n type CronFieldName,\n type CronFrequency,\n type CronTerm,\n} from \"./utils/cron.js\";\nexport {\n tokens,\n tokenValues,\n darkTokenValues,\n gradientTokenValues,\n metroTokenValues,\n blueprintTokenValues,\n developerDarkTokenValues,\n developerLightTokenValues,\n} from \"./tokens.js\";\nexport * from \"./icons.js\";\nexport { BlinkCursor } from \"./blink-cursor.js\";\nexport { CommentLabel } from \"./comment-label.js\";\nexport { StatStrip, type StatStripItem } from \"./stat-strip.js\";\nexport { StepLadder, type StepLadderItem } from \"./step-ladder.js\";\nexport {\n TerminalBlock,\n type TerminalLine,\n type TerminalLineType,\n} from \"./terminal-block.js\";\nexport { CodeDiff, type CodeDiffLine, type CodeDiffLineType } from \"./code-diff.js\";\nexport { WindowChrome } from \"./window-chrome.js\";\n"]}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import { LitElement, type PropertyValues } from "lit";
|
|
2
|
+
/**
|
|
3
|
+
* Pixelated, 8-bit style fire in the manner of old computer games. By default
|
|
4
|
+
* it is pinned full width to the bottom of the viewport as a decorative,
|
|
5
|
+
* click-through overlay; `contained` pins it to the bottom of the nearest
|
|
6
|
+
* positioned ancestor instead.
|
|
7
|
+
*
|
|
8
|
+
* The strip's height is set with `--pixel-fire-height` (default `8rem`). It
|
|
9
|
+
* paints at `z-index: 30`, above ordinary page content but below `app-shell`'s
|
|
10
|
+
* chrome and every dialog or popover. Under `prefers-reduced-motion: reduce`
|
|
11
|
+
* it draws one still frame instead of animating. The canvas is hidden from
|
|
12
|
+
* assistive technology.
|
|
13
|
+
*
|
|
14
|
+
* @element pixel-fire
|
|
15
|
+
*/
|
|
16
|
+
export declare class PixelFire extends LitElement {
|
|
17
|
+
/** Size of one fire pixel in CSS pixels; larger values look chunkier. */
|
|
18
|
+
pixelSize: number;
|
|
19
|
+
/**
|
|
20
|
+
* Heat of the fire's source, from `0` to `1`. Lowering it shortens the
|
|
21
|
+
* flames; `0` lets the fire burn out.
|
|
22
|
+
*/
|
|
23
|
+
intensity: number;
|
|
24
|
+
/**
|
|
25
|
+
* Pins the fire to the bottom of the nearest positioned ancestor instead of
|
|
26
|
+
* the viewport.
|
|
27
|
+
*/
|
|
28
|
+
contained: boolean;
|
|
29
|
+
private _cols;
|
|
30
|
+
private _rows;
|
|
31
|
+
private _heat;
|
|
32
|
+
private _cooling;
|
|
33
|
+
private _time;
|
|
34
|
+
private _image?;
|
|
35
|
+
private _frame?;
|
|
36
|
+
private _lastStep;
|
|
37
|
+
private _resizeObserver?;
|
|
38
|
+
private _motionQuery?;
|
|
39
|
+
static styles: import("lit").CSSResult[];
|
|
40
|
+
connectedCallback(): void;
|
|
41
|
+
disconnectedCallback(): void;
|
|
42
|
+
protected firstUpdated(): void;
|
|
43
|
+
protected updated(changed: PropertyValues<this>): void;
|
|
44
|
+
render(): import("lit-html").TemplateResult<1>;
|
|
45
|
+
private get _canvas();
|
|
46
|
+
private get _cellSize();
|
|
47
|
+
private get _sourceHeat();
|
|
48
|
+
/** Rebuilds the fire grid to cover the host's current box, then restarts it. */
|
|
49
|
+
private readonly _resize;
|
|
50
|
+
/** Animates the fire, or draws one settled frame under reduced motion. */
|
|
51
|
+
private readonly _restart;
|
|
52
|
+
private _stop;
|
|
53
|
+
private readonly _tick;
|
|
54
|
+
/**
|
|
55
|
+
* Advances the fire one step: the bottom row is fed with heat and every cell
|
|
56
|
+
* rises one row, drifting sideways and cooling at random.
|
|
57
|
+
*
|
|
58
|
+
* @returns Whether any cell is still burning.
|
|
59
|
+
*/
|
|
60
|
+
private _step;
|
|
61
|
+
/** Paints the heat grid to the canvas through the palette. */
|
|
62
|
+
private _draw;
|
|
63
|
+
}
|
|
64
|
+
declare global {
|
|
65
|
+
interface HTMLElementTagNameMap {
|
|
66
|
+
"pixel-fire": PixelFire;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
//# sourceMappingURL=pixel-fire.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pixel-fire.d.ts","sourceRoot":"","sources":["../src/pixel-fire.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,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,YAAY,EAAE,SAAS,CAAC;KACzB;CACF"}
|
|
@@ -0,0 +1,296 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
import { LitElement, css, html } from "lit";
|
|
8
|
+
import { customElement, property } from "lit/decorators.js";
|
|
9
|
+
import { tokens } from "./tokens.js";
|
|
10
|
+
/**
|
|
11
|
+
* The classic 8-bit fire ramp, from cold (index 0, drawn transparent) to the
|
|
12
|
+
* white-hot base. Literal colors by design: the retro palette is the effect
|
|
13
|
+
* and stays independent of the theme.
|
|
14
|
+
*/
|
|
15
|
+
const PALETTE = [
|
|
16
|
+
[0x07, 0x07, 0x07], [0x1f, 0x07, 0x07], [0x2f, 0x0f, 0x07], [0x47, 0x0f, 0x07],
|
|
17
|
+
[0x57, 0x17, 0x07], [0x67, 0x1f, 0x07], [0x77, 0x1f, 0x07], [0x8f, 0x27, 0x07],
|
|
18
|
+
[0x9f, 0x2f, 0x07], [0xaf, 0x3f, 0x07], [0xbf, 0x47, 0x07], [0xc7, 0x47, 0x07],
|
|
19
|
+
[0xdf, 0x4f, 0x07], [0xdf, 0x57, 0x07], [0xdf, 0x57, 0x07], [0xd7, 0x5f, 0x07],
|
|
20
|
+
[0xd7, 0x5f, 0x07], [0xd7, 0x67, 0x0f], [0xcf, 0x6f, 0x0f], [0xcf, 0x77, 0x0f],
|
|
21
|
+
[0xcf, 0x7f, 0x0f], [0xcf, 0x87, 0x17], [0xc7, 0x87, 0x17], [0xc7, 0x8f, 0x17],
|
|
22
|
+
[0xc7, 0x97, 0x1f], [0xbf, 0x9f, 0x1f], [0xbf, 0x9f, 0x1f], [0xbf, 0xa7, 0x27],
|
|
23
|
+
[0xbf, 0xa7, 0x27], [0xbf, 0xaf, 0x2f], [0xb7, 0xaf, 0x2f], [0xb7, 0xb7, 0x2f],
|
|
24
|
+
[0xb7, 0xb7, 0x37], [0xcf, 0xcf, 0x6f], [0xdf, 0xdf, 0x9f], [0xef, 0xef, 0xc7],
|
|
25
|
+
[0xff, 0xff, 0xff],
|
|
26
|
+
];
|
|
27
|
+
const MAX_HEAT = PALETTE.length - 1;
|
|
28
|
+
/** Fraction of the strip's height the tallest flames reach at full intensity. */
|
|
29
|
+
const FLAME_REACH = 0.8;
|
|
30
|
+
/** Simulation steps per second; the low rate is part of the retro look. */
|
|
31
|
+
const STEPS_PER_SECOND = 30;
|
|
32
|
+
const STEP_MS = 1000 / STEPS_PER_SECOND;
|
|
33
|
+
/** Share of cooling that follows the rising cooling map rather than per-cell noise. */
|
|
34
|
+
const MAP_WEIGHT = 0.7;
|
|
35
|
+
/** Coldest palette steps, which fade in from transparent so flame tips read as smoke. */
|
|
36
|
+
const SMOKE_STEPS = 6;
|
|
37
|
+
/**
|
|
38
|
+
* Builds a smooth, high-contrast noise field with a mean of `0.5`. It wraps
|
|
39
|
+
* vertically so it can scroll upward with the flames, carving them into
|
|
40
|
+
* rising tongues.
|
|
41
|
+
*/
|
|
42
|
+
function coolingMap(cols, rows) {
|
|
43
|
+
let map = new Float32Array(cols * rows);
|
|
44
|
+
for (let i = 0; i < map.length; i++)
|
|
45
|
+
map[i] = Math.random();
|
|
46
|
+
for (let pass = 0; pass < 4; pass++)
|
|
47
|
+
map = blur(map, cols, rows);
|
|
48
|
+
let min = Infinity;
|
|
49
|
+
let max = -Infinity;
|
|
50
|
+
for (const value of map) {
|
|
51
|
+
min = Math.min(min, value);
|
|
52
|
+
max = Math.max(max, value);
|
|
53
|
+
}
|
|
54
|
+
const range = max - min || 1;
|
|
55
|
+
let sum = 0;
|
|
56
|
+
for (let i = 0; i < map.length; i++) {
|
|
57
|
+
map[i] = ((map[i] - min) / range) ** 2;
|
|
58
|
+
sum += map[i];
|
|
59
|
+
}
|
|
60
|
+
const scale = (0.5 * map.length) / (sum || 1);
|
|
61
|
+
for (let i = 0; i < map.length; i++)
|
|
62
|
+
map[i] *= scale;
|
|
63
|
+
return map;
|
|
64
|
+
}
|
|
65
|
+
/** 3×3 box blur that clamps horizontally and wraps vertically. */
|
|
66
|
+
function blur(source, cols, rows) {
|
|
67
|
+
const out = new Float32Array(source.length);
|
|
68
|
+
for (let y = 0; y < rows; y++) {
|
|
69
|
+
for (let x = 0; x < cols; x++) {
|
|
70
|
+
let sum = 0;
|
|
71
|
+
for (let dy = -1; dy <= 1; dy++) {
|
|
72
|
+
const row = ((y + dy + rows) % rows) * cols;
|
|
73
|
+
for (let dx = -1; dx <= 1; dx++) {
|
|
74
|
+
sum += source[row + Math.min(cols - 1, Math.max(0, x + dx))];
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
out[y * cols + x] = sum / 9;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
return out;
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Pixelated, 8-bit style fire in the manner of old computer games. By default
|
|
84
|
+
* it is pinned full width to the bottom of the viewport as a decorative,
|
|
85
|
+
* click-through overlay; `contained` pins it to the bottom of the nearest
|
|
86
|
+
* positioned ancestor instead.
|
|
87
|
+
*
|
|
88
|
+
* The strip's height is set with `--pixel-fire-height` (default `8rem`). It
|
|
89
|
+
* paints at `z-index: 30`, above ordinary page content but below `app-shell`'s
|
|
90
|
+
* chrome and every dialog or popover. Under `prefers-reduced-motion: reduce`
|
|
91
|
+
* it draws one still frame instead of animating. The canvas is hidden from
|
|
92
|
+
* assistive technology.
|
|
93
|
+
*
|
|
94
|
+
* @element pixel-fire
|
|
95
|
+
*/
|
|
96
|
+
let PixelFire = class PixelFire extends LitElement {
|
|
97
|
+
constructor() {
|
|
98
|
+
super(...arguments);
|
|
99
|
+
/** Size of one fire pixel in CSS pixels; larger values look chunkier. */
|
|
100
|
+
this.pixelSize = 4;
|
|
101
|
+
/**
|
|
102
|
+
* Heat of the fire's source, from `0` to `1`. Lowering it shortens the
|
|
103
|
+
* flames; `0` lets the fire burn out.
|
|
104
|
+
*/
|
|
105
|
+
this.intensity = 1;
|
|
106
|
+
/**
|
|
107
|
+
* Pins the fire to the bottom of the nearest positioned ancestor instead of
|
|
108
|
+
* the viewport.
|
|
109
|
+
*/
|
|
110
|
+
this.contained = false;
|
|
111
|
+
this._cols = 0;
|
|
112
|
+
this._rows = 0;
|
|
113
|
+
this._heat = new Float32Array(0);
|
|
114
|
+
this._cooling = new Float32Array(0);
|
|
115
|
+
this._time = 0;
|
|
116
|
+
this._lastStep = 0;
|
|
117
|
+
/** Rebuilds the fire grid to cover the host's current box, then restarts it. */
|
|
118
|
+
this._resize = () => {
|
|
119
|
+
const canvas = this._canvas;
|
|
120
|
+
if (!canvas)
|
|
121
|
+
return;
|
|
122
|
+
const size = this._cellSize;
|
|
123
|
+
const cols = Math.ceil(this.clientWidth / size);
|
|
124
|
+
const rows = Math.ceil(this.clientHeight / size);
|
|
125
|
+
this._cols = cols;
|
|
126
|
+
this._rows = rows;
|
|
127
|
+
this._heat = new Float32Array(cols * rows);
|
|
128
|
+
this._cooling = coolingMap(cols, rows);
|
|
129
|
+
canvas.width = cols;
|
|
130
|
+
canvas.height = rows;
|
|
131
|
+
canvas.style.width = `${cols * size}px`;
|
|
132
|
+
canvas.style.height = `${rows * size}px`;
|
|
133
|
+
this._image = cols > 0 && rows > 0 ? new ImageData(cols, rows) : undefined;
|
|
134
|
+
this._restart();
|
|
135
|
+
};
|
|
136
|
+
/** Animates the fire, or draws one settled frame under reduced motion. */
|
|
137
|
+
this._restart = () => {
|
|
138
|
+
this._stop();
|
|
139
|
+
if (!this._image)
|
|
140
|
+
return;
|
|
141
|
+
if (this._motionQuery?.matches) {
|
|
142
|
+
for (let i = 0; i < this._rows * 2; i++)
|
|
143
|
+
this._step();
|
|
144
|
+
this._draw();
|
|
145
|
+
return;
|
|
146
|
+
}
|
|
147
|
+
this._frame = window.requestAnimationFrame(this._tick);
|
|
148
|
+
};
|
|
149
|
+
this._tick = (time) => {
|
|
150
|
+
this._frame = undefined;
|
|
151
|
+
if (time - this._lastStep >= STEP_MS) {
|
|
152
|
+
this._lastStep = time;
|
|
153
|
+
const burning = this._step();
|
|
154
|
+
this._draw();
|
|
155
|
+
if (!burning)
|
|
156
|
+
return;
|
|
157
|
+
}
|
|
158
|
+
this._frame = window.requestAnimationFrame(this._tick);
|
|
159
|
+
};
|
|
160
|
+
}
|
|
161
|
+
static { this.styles = [
|
|
162
|
+
tokens,
|
|
163
|
+
css `
|
|
164
|
+
:host {
|
|
165
|
+
display: block;
|
|
166
|
+
position: fixed;
|
|
167
|
+
inset: auto 0 0 0;
|
|
168
|
+
z-index: 30;
|
|
169
|
+
height: var(--pixel-fire-height, 8rem);
|
|
170
|
+
overflow: hidden;
|
|
171
|
+
pointer-events: none;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
:host([contained]) {
|
|
175
|
+
position: absolute;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
:host([hidden]) {
|
|
179
|
+
display: none;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
canvas {
|
|
183
|
+
position: absolute;
|
|
184
|
+
left: 0;
|
|
185
|
+
bottom: 0;
|
|
186
|
+
display: block;
|
|
187
|
+
image-rendering: pixelated;
|
|
188
|
+
}
|
|
189
|
+
`,
|
|
190
|
+
]; }
|
|
191
|
+
connectedCallback() {
|
|
192
|
+
super.connectedCallback();
|
|
193
|
+
this._motionQuery = window.matchMedia("(prefers-reduced-motion: reduce)");
|
|
194
|
+
this._motionQuery.addEventListener("change", this._restart);
|
|
195
|
+
this._resizeObserver = new ResizeObserver(this._resize);
|
|
196
|
+
this._resizeObserver.observe(this);
|
|
197
|
+
}
|
|
198
|
+
disconnectedCallback() {
|
|
199
|
+
super.disconnectedCallback();
|
|
200
|
+
this._motionQuery?.removeEventListener("change", this._restart);
|
|
201
|
+
this._motionQuery = undefined;
|
|
202
|
+
this._resizeObserver?.disconnect();
|
|
203
|
+
this._resizeObserver = undefined;
|
|
204
|
+
this._stop();
|
|
205
|
+
}
|
|
206
|
+
firstUpdated() {
|
|
207
|
+
this._resize();
|
|
208
|
+
}
|
|
209
|
+
updated(changed) {
|
|
210
|
+
if (changed.has("pixelSize") && changed.get("pixelSize") !== undefined) {
|
|
211
|
+
this._resize();
|
|
212
|
+
return;
|
|
213
|
+
}
|
|
214
|
+
if (changed.has("intensity") && changed.get("intensity") !== undefined) {
|
|
215
|
+
this._restart();
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
render() {
|
|
219
|
+
return html `<canvas aria-hidden="true"></canvas>`;
|
|
220
|
+
}
|
|
221
|
+
get _canvas() {
|
|
222
|
+
return this.renderRoot.querySelector("canvas");
|
|
223
|
+
}
|
|
224
|
+
get _cellSize() {
|
|
225
|
+
return Math.max(1, Math.round(this.pixelSize) || 1);
|
|
226
|
+
}
|
|
227
|
+
get _sourceHeat() {
|
|
228
|
+
const intensity = Number.isFinite(this.intensity) ? this.intensity : 1;
|
|
229
|
+
return Math.min(1, Math.max(0, intensity)) * MAX_HEAT;
|
|
230
|
+
}
|
|
231
|
+
_stop() {
|
|
232
|
+
if (this._frame === undefined)
|
|
233
|
+
return;
|
|
234
|
+
window.cancelAnimationFrame(this._frame);
|
|
235
|
+
this._frame = undefined;
|
|
236
|
+
}
|
|
237
|
+
/**
|
|
238
|
+
* Advances the fire one step: the bottom row is fed with heat and every cell
|
|
239
|
+
* rises one row, drifting sideways and cooling at random.
|
|
240
|
+
*
|
|
241
|
+
* @returns Whether any cell is still burning.
|
|
242
|
+
*/
|
|
243
|
+
_step() {
|
|
244
|
+
const cols = this._cols;
|
|
245
|
+
const rows = this._rows;
|
|
246
|
+
const heat = this._heat;
|
|
247
|
+
const cooling = this._cooling;
|
|
248
|
+
const meanCooling = MAX_HEAT / Math.max(1, (rows - 1) * FLAME_REACH);
|
|
249
|
+
this._time = (this._time + 1) % rows;
|
|
250
|
+
heat.fill(this._sourceHeat, (rows - 1) * cols);
|
|
251
|
+
for (let y = 0; y < rows - 1; y++) {
|
|
252
|
+
const mapRow = ((y + this._time) % rows) * cols;
|
|
253
|
+
for (let x = 0; x < cols; x++) {
|
|
254
|
+
const below = heat[(y + 1) * cols + x];
|
|
255
|
+
const drift = Math.min(cols - 1, Math.max(0, x + Math.round(Math.random() * 2 - 1)));
|
|
256
|
+
const local = MAP_WEIGHT * cooling[mapRow + x] + (1 - MAP_WEIGHT) * Math.random();
|
|
257
|
+
heat[y * cols + drift] = Math.max(0, below - 2 * meanCooling * local);
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
// Cells no drift landed on keep their old heat, so scan the whole grid.
|
|
261
|
+
return heat.some((value) => value > 0);
|
|
262
|
+
}
|
|
263
|
+
/** Paints the heat grid to the canvas through the palette. */
|
|
264
|
+
_draw() {
|
|
265
|
+
const image = this._image;
|
|
266
|
+
const context = this._canvas?.getContext("2d");
|
|
267
|
+
if (!image || !context)
|
|
268
|
+
return;
|
|
269
|
+
const data = image.data;
|
|
270
|
+
const heat = this._heat;
|
|
271
|
+
for (let i = 0; i < heat.length; i++) {
|
|
272
|
+
const index = Math.min(MAX_HEAT, Math.floor(heat[i]));
|
|
273
|
+
const [r, g, b] = PALETTE[index];
|
|
274
|
+
const offset = i * 4;
|
|
275
|
+
data[offset] = r;
|
|
276
|
+
data[offset + 1] = g;
|
|
277
|
+
data[offset + 2] = b;
|
|
278
|
+
data[offset + 3] = Math.min(255, Math.round((255 * index) / SMOKE_STEPS));
|
|
279
|
+
}
|
|
280
|
+
context.putImageData(image, 0, 0);
|
|
281
|
+
}
|
|
282
|
+
};
|
|
283
|
+
__decorate([
|
|
284
|
+
property({ type: Number, attribute: "pixel-size" })
|
|
285
|
+
], PixelFire.prototype, "pixelSize", void 0);
|
|
286
|
+
__decorate([
|
|
287
|
+
property({ type: Number })
|
|
288
|
+
], PixelFire.prototype, "intensity", void 0);
|
|
289
|
+
__decorate([
|
|
290
|
+
property({ type: Boolean, reflect: true })
|
|
291
|
+
], PixelFire.prototype, "contained", void 0);
|
|
292
|
+
PixelFire = __decorate([
|
|
293
|
+
customElement("pixel-fire")
|
|
294
|
+
], PixelFire);
|
|
295
|
+
export { PixelFire };
|
|
296
|
+
//# sourceMappingURL=pixel-fire.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pixel-fire.js","sourceRoot":"","sources":["../src/pixel-fire.ts"],"names":[],"mappings":";;;;;;AAAA,OAAO,EAAE,UAAU,EAAE,GAAG,EAAE,IAAI,EAAuB,MAAM,KAAK,CAAC;AACjE,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAErC;;;;GAIG;AACH,MAAM,OAAO,GAAqD;IAChE,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC;IAC9E,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC;IAC9E,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI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C,CAAC;QAC5E,CAAC;QACD,OAAO,CAAC,YAAY,CAAC,KAAK,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;IACpC,CAAC;CACF,CAAA;AAxMC;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,YAAY,EAAE,CAAC;4CAC9B;AAOtB;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;4CACL;AAOtB;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;4CAChB;AAjBhB,SAAS;IADrB,aAAa,CAAC,YAAY,CAAC;GACf,SAAS,CA2MrB","sourcesContent":["import { LitElement, css, html, type PropertyValues } from \"lit\";\nimport { customElement, property } from \"lit/decorators.js\";\nimport { tokens } from \"./tokens.js\";\n\n/**\n * The classic 8-bit fire ramp, from cold (index 0, drawn transparent) to the\n * white-hot base. Literal colors by design: the retro palette is the effect\n * and stays independent of the theme.\n */\nconst PALETTE: ReadonlyArray<readonly [number, number, number]> = [\n [0x07, 0x07, 0x07], [0x1f, 0x07, 0x07], [0x2f, 0x0f, 0x07], [0x47, 0x0f, 0x07],\n [0x57, 0x17, 0x07], [0x67, 0x1f, 0x07], [0x77, 0x1f, 0x07], [0x8f, 0x27, 0x07],\n [0x9f, 0x2f, 0x07], [0xaf, 0x3f, 0x07], [0xbf, 0x47, 0x07], [0xc7, 0x47, 0x07],\n [0xdf, 0x4f, 0x07], [0xdf, 0x57, 0x07], [0xdf, 0x57, 0x07], [0xd7, 0x5f, 0x07],\n [0xd7, 0x5f, 0x07], [0xd7, 0x67, 0x0f], [0xcf, 0x6f, 0x0f], [0xcf, 0x77, 0x0f],\n [0xcf, 0x7f, 0x0f], [0xcf, 0x87, 0x17], [0xc7, 0x87, 0x17], [0xc7, 0x8f, 0x17],\n [0xc7, 0x97, 0x1f], [0xbf, 0x9f, 0x1f], [0xbf, 0x9f, 0x1f], [0xbf, 0xa7, 0x27],\n [0xbf, 0xa7, 0x27], [0xbf, 0xaf, 0x2f], [0xb7, 0xaf, 0x2f], [0xb7, 0xb7, 0x2f],\n [0xb7, 0xb7, 0x37], [0xcf, 0xcf, 0x6f], [0xdf, 0xdf, 0x9f], [0xef, 0xef, 0xc7],\n [0xff, 0xff, 0xff],\n];\nconst MAX_HEAT = PALETTE.length - 1;\n/** Fraction of the strip's height the tallest flames reach at full intensity. */\nconst FLAME_REACH = 0.8;\n/** Simulation steps per second; the low rate is part of the retro look. */\nconst STEPS_PER_SECOND = 30;\nconst STEP_MS = 1000 / STEPS_PER_SECOND;\n/** Share of cooling that follows the rising cooling map rather than per-cell noise. */\nconst MAP_WEIGHT = 0.7;\n/** Coldest palette steps, which fade in from transparent so flame tips read as smoke. */\nconst SMOKE_STEPS = 6;\n\n/**\n * Builds a smooth, high-contrast noise field with a mean of `0.5`. It wraps\n * vertically so it can scroll upward with the flames, carving them into\n * rising tongues.\n */\nfunction coolingMap(cols: number, rows: number): Float32Array {\n let map: Float32Array = new Float32Array(cols * rows);\n for (let i = 0; i < map.length; i++) map[i] = Math.random();\n for (let pass = 0; pass < 4; pass++) map = blur(map, cols, rows);\n let min = Infinity;\n let max = -Infinity;\n for (const value of map) {\n min = Math.min(min, value);\n max = Math.max(max, value);\n }\n const range = max - min || 1;\n let sum = 0;\n for (let i = 0; i < map.length; i++) {\n map[i] = ((map[i] - min) / range) ** 2;\n sum += map[i];\n }\n const scale = (0.5 * map.length) / (sum || 1);\n for (let i = 0; i < map.length; i++) map[i] *= scale;\n return map;\n}\n\n/** 3×3 box blur that clamps horizontally and wraps vertically. */\nfunction blur(source: Float32Array, cols: number, rows: number): Float32Array {\n const out = new Float32Array(source.length);\n for (let y = 0; y < rows; y++) {\n for (let x = 0; x < cols; x++) {\n let sum = 0;\n for (let dy = -1; dy <= 1; dy++) {\n const row = ((y + dy + rows) % rows) * cols;\n for (let dx = -1; dx <= 1; dx++) {\n sum += source[row + Math.min(cols - 1, Math.max(0, x + dx))];\n }\n }\n out[y * cols + x] = sum / 9;\n }\n }\n return out;\n}\n\n/**\n * Pixelated, 8-bit style fire in the manner of old computer games. By default\n * it is pinned full width to the bottom of the viewport as a decorative,\n * click-through overlay; `contained` pins it to the bottom of the nearest\n * positioned ancestor instead.\n *\n * The strip's height is set with `--pixel-fire-height` (default `8rem`). It\n * paints at `z-index: 30`, above ordinary page content but below `app-shell`'s\n * chrome and every dialog or popover. Under `prefers-reduced-motion: reduce`\n * it draws one still frame instead of animating. The canvas is hidden from\n * assistive technology.\n *\n * @element pixel-fire\n */\n@customElement(\"pixel-fire\")\nexport class PixelFire extends LitElement {\n /** Size of one fire pixel in CSS pixels; larger values look chunkier. */\n @property({ type: Number, attribute: \"pixel-size\" })\n pixelSize: number = 4;\n\n /**\n * Heat of the fire's source, from `0` to `1`. Lowering it shortens the\n * flames; `0` lets the fire burn out.\n */\n @property({ type: Number })\n intensity: number = 1;\n\n /**\n * Pins the fire to the bottom of the nearest positioned ancestor instead of\n * the viewport.\n */\n @property({ type: Boolean, reflect: true })\n contained: boolean = false;\n\n private _cols = 0;\n private _rows = 0;\n private _heat = new Float32Array(0);\n private _cooling: Float32Array = new Float32Array(0);\n private _time = 0;\n private _image?: ImageData;\n private _frame?: number;\n private _lastStep = 0;\n private _resizeObserver?: ResizeObserver;\n private _motionQuery?: MediaQueryList;\n\n static override styles = [\n tokens,\n css`\n :host {\n display: block;\n position: fixed;\n inset: auto 0 0 0;\n z-index: 30;\n height: var(--pixel-fire-height, 8rem);\n overflow: hidden;\n pointer-events: none;\n }\n\n :host([contained]) {\n position: absolute;\n }\n\n :host([hidden]) {\n display: none;\n }\n\n canvas {\n position: absolute;\n left: 0;\n bottom: 0;\n display: block;\n image-rendering: pixelated;\n }\n `,\n ];\n\n override connectedCallback(): void {\n super.connectedCallback();\n this._motionQuery = window.matchMedia(\"(prefers-reduced-motion: reduce)\");\n this._motionQuery.addEventListener(\"change\", this._restart);\n this._resizeObserver = new ResizeObserver(this._resize);\n this._resizeObserver.observe(this);\n }\n\n override disconnectedCallback(): void {\n super.disconnectedCallback();\n this._motionQuery?.removeEventListener(\"change\", this._restart);\n this._motionQuery = undefined;\n this._resizeObserver?.disconnect();\n this._resizeObserver = undefined;\n this._stop();\n }\n\n protected override firstUpdated(): void {\n this._resize();\n }\n\n protected override updated(changed: PropertyValues<this>): void {\n if (changed.has(\"pixelSize\") && changed.get(\"pixelSize\") !== undefined) {\n this._resize();\n return;\n }\n if (changed.has(\"intensity\") && changed.get(\"intensity\") !== undefined) {\n this._restart();\n }\n }\n\n override render() {\n return html`<canvas aria-hidden=\"true\"></canvas>`;\n }\n\n private get _canvas(): HTMLCanvasElement | null {\n return this.renderRoot.querySelector(\"canvas\");\n }\n\n private get _cellSize(): number {\n return Math.max(1, Math.round(this.pixelSize) || 1);\n }\n\n private get _sourceHeat(): number {\n const intensity = Number.isFinite(this.intensity) ? this.intensity : 1;\n return Math.min(1, Math.max(0, intensity)) * MAX_HEAT;\n }\n\n /** Rebuilds the fire grid to cover the host's current box, then restarts it. */\n private readonly _resize = (): void => {\n const canvas = this._canvas;\n if (!canvas) return;\n const size = this._cellSize;\n const cols = Math.ceil(this.clientWidth / size);\n const rows = Math.ceil(this.clientHeight / size);\n this._cols = cols;\n this._rows = rows;\n this._heat = new Float32Array(cols * rows);\n this._cooling = coolingMap(cols, rows);\n canvas.width = cols;\n canvas.height = rows;\n canvas.style.width = `${cols * size}px`;\n canvas.style.height = `${rows * size}px`;\n this._image = cols > 0 && rows > 0 ? new ImageData(cols, rows) : undefined;\n this._restart();\n };\n\n /** Animates the fire, or draws one settled frame under reduced motion. */\n private readonly _restart = (): void => {\n this._stop();\n if (!this._image) return;\n if (this._motionQuery?.matches) {\n for (let i = 0; i < this._rows * 2; i++) this._step();\n this._draw();\n return;\n }\n this._frame = window.requestAnimationFrame(this._tick);\n };\n\n private _stop(): void {\n if (this._frame === undefined) return;\n window.cancelAnimationFrame(this._frame);\n this._frame = undefined;\n }\n\n private readonly _tick = (time: number): void => {\n this._frame = undefined;\n if (time - this._lastStep >= STEP_MS) {\n this._lastStep = time;\n const burning = this._step();\n this._draw();\n if (!burning) return;\n }\n this._frame = window.requestAnimationFrame(this._tick);\n };\n\n /**\n * Advances the fire one step: the bottom row is fed with heat and every cell\n * rises one row, drifting sideways and cooling at random.\n *\n * @returns Whether any cell is still burning.\n */\n private _step(): boolean {\n const cols = this._cols;\n const rows = this._rows;\n const heat = this._heat;\n const cooling = this._cooling;\n const meanCooling = MAX_HEAT / Math.max(1, (rows - 1) * FLAME_REACH);\n this._time = (this._time + 1) % rows;\n\n heat.fill(this._sourceHeat, (rows - 1) * cols);\n for (let y = 0; y < rows - 1; y++) {\n const mapRow = ((y + this._time) % rows) * cols;\n for (let x = 0; x < cols; x++) {\n const below = heat[(y + 1) * cols + x];\n const drift = Math.min(cols - 1, Math.max(0, x + Math.round(Math.random() * 2 - 1)));\n const local = MAP_WEIGHT * cooling[mapRow + x] + (1 - MAP_WEIGHT) * Math.random();\n heat[y * cols + drift] = Math.max(0, below - 2 * meanCooling * local);\n }\n }\n // Cells no drift landed on keep their old heat, so scan the whole grid.\n return heat.some((value) => value > 0);\n }\n\n /** Paints the heat grid to the canvas through the palette. */\n private _draw(): void {\n const image = this._image;\n const context = this._canvas?.getContext(\"2d\");\n if (!image || !context) return;\n const data = image.data;\n const heat = this._heat;\n for (let i = 0; i < heat.length; i++) {\n const index = Math.min(MAX_HEAT, Math.floor(heat[i]));\n const [r, g, b] = PALETTE[index];\n const offset = i * 4;\n data[offset] = r;\n data[offset + 1] = g;\n data[offset + 2] = b;\n data[offset + 3] = Math.min(255, Math.round((255 * index) / SMOKE_STEPS));\n }\n context.putImageData(image, 0, 0);\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"pixel-fire\": PixelFire;\n }\n}\n"]}
|
package/docs/design-language.md
CHANGED
|
@@ -70,9 +70,9 @@ defines the details used when creating or reviewing components.
|
|
|
70
70
|
- Plain SVG presentation attributes may use literal token fallback values when
|
|
71
71
|
CSS variables are not practical. User-provided marker/chart colors are an
|
|
72
72
|
explicit exception.
|
|
73
|
-
- White map rings, image-overlay controls, avatar foregrounds,
|
|
74
|
-
confetti may remain literal when their
|
|
75
|
-
of the surrounding theme.
|
|
73
|
+
- White map rings, image-overlay controls, avatar foregrounds, celebratory
|
|
74
|
+
confetti, and `pixel-fire`'s retro fire palette may remain literal when their
|
|
75
|
+
contrast is intentionally independent of the surrounding theme.
|
|
76
76
|
- There is no dedicated secondary accent color. `tab-bar`'s inactive-tab
|
|
77
77
|
indicator reuses `--ui-border` (a shared line beneath the whole strip, with
|
|
78
78
|
the active tab's `--ui-primary` line drawn on top of it) rather than
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
# `<pixel-fire>`
|
|
2
|
+
|
|
3
|
+
Pixelated, 8-bit style fire in the manner of old computer games. By default
|
|
4
|
+
it is pinned full width to the bottom of the viewport as a decorative,
|
|
5
|
+
click-through overlay; `contained` pins it to the bottom of the nearest
|
|
6
|
+
positioned ancestor instead.
|
|
7
|
+
|
|
8
|
+
The strip's height is set with `--pixel-fire-height` (default `8rem`). It
|
|
9
|
+
paints at `z-index: 30`, above ordinary page content but below `app-shell`'s
|
|
10
|
+
chrome and every dialog or popover. Under `prefers-reduced-motion: reduce`
|
|
11
|
+
it draws one still frame instead of animating. The canvas is hidden from
|
|
12
|
+
assistive technology.
|
|
13
|
+
|
|
14
|
+
## Install
|
|
15
|
+
|
|
16
|
+
```js
|
|
17
|
+
import "@f-ewald/components/pixel-fire.js";
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
## Usage
|
|
21
|
+
|
|
22
|
+
```html
|
|
23
|
+
<!-- Full width along the bottom of the viewport -->
|
|
24
|
+
<pixel-fire></pixel-fire>
|
|
25
|
+
|
|
26
|
+
<!-- Along the bottom of a positioned container, chunkier and lower -->
|
|
27
|
+
<div style="position: relative; height: 12rem">
|
|
28
|
+
<pixel-fire contained pixel-size="8" intensity="0.6"
|
|
29
|
+
style="--pixel-fire-height: 6rem"></pixel-fire>
|
|
30
|
+
</div>
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
## Attributes / properties
|
|
34
|
+
|
|
35
|
+
| Property | Attribute | Type | Default | Description |
|
|
36
|
+
| --- | --- | --- | --- | --- |
|
|
37
|
+
| `pixelSize` | `pixel-size` | `number` | `4` | Size of one fire pixel in CSS pixels; larger values look chunkier. |
|
|
38
|
+
| `intensity` | `intensity` | `number` | `1` | Heat of the fire's source, from `0` to `1`. Lowering it shortens the flames; `0` lets the fire burn out. |
|
|
39
|
+
| `contained` | `contained` | `boolean` | `false` | Pins the fire to the bottom of the nearest positioned ancestor instead of the viewport. |
|
|
40
|
+
|
|
41
|
+
## Events
|
|
42
|
+
|
|
43
|
+
_None._
|
|
44
|
+
|
|
45
|
+
## Slots
|
|
46
|
+
|
|
47
|
+
_None._
|
|
48
|
+
|
|
49
|
+
## CSS custom properties
|
|
50
|
+
|
|
51
|
+
_None._
|
package/llms.txt
CHANGED
|
@@ -2067,6 +2067,37 @@ Example:
|
|
|
2067
2067
|
</script>
|
|
2068
2068
|
```
|
|
2069
2069
|
|
|
2070
|
+
## <pixel-fire>
|
|
2071
|
+
|
|
2072
|
+
Pixelated, 8-bit style fire in the manner of old computer games. By default
|
|
2073
|
+
it is pinned full width to the bottom of the viewport as a decorative,
|
|
2074
|
+
click-through overlay; `contained` pins it to the bottom of the nearest
|
|
2075
|
+
positioned ancestor instead.
|
|
2076
|
+
|
|
2077
|
+
The strip's height is set with `--pixel-fire-height` (default `8rem`). It
|
|
2078
|
+
paints at `z-index: 30`, above ordinary page content but below `app-shell`'s
|
|
2079
|
+
chrome and every dialog or popover. Under `prefers-reduced-motion: reduce`
|
|
2080
|
+
it draws one still frame instead of animating. The canvas is hidden from
|
|
2081
|
+
assistive technology.
|
|
2082
|
+
|
|
2083
|
+
Import: `import "@f-ewald/components/pixel-fire.js";`
|
|
2084
|
+
|
|
2085
|
+
Properties: `pixelSize` (attribute `pixel-size`) : number, default 4; `intensity` (attribute `intensity`) : number, default 1; `contained` (attribute `contained`) : boolean, default false
|
|
2086
|
+
Events: none
|
|
2087
|
+
CSS custom properties: none
|
|
2088
|
+
|
|
2089
|
+
Example:
|
|
2090
|
+
```html
|
|
2091
|
+
<!-- Full width along the bottom of the viewport -->
|
|
2092
|
+
<pixel-fire></pixel-fire>
|
|
2093
|
+
|
|
2094
|
+
<!-- Along the bottom of a positioned container, chunkier and lower -->
|
|
2095
|
+
<div style="position: relative; height: 12rem">
|
|
2096
|
+
<pixel-fire contained pixel-size="8" intensity="0.6"
|
|
2097
|
+
style="--pixel-fire-height: 6rem"></pixel-fire>
|
|
2098
|
+
</div>
|
|
2099
|
+
```
|
|
2100
|
+
|
|
2070
2101
|
## <popover-panel>
|
|
2071
2102
|
|
|
2072
2103
|
Generic anchored popover shell: a floating card positioned relative to its
|