@fusion.dev/helix 0.161.0 → 0.162.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/custom-elements.json +2501 -13
- package/dist/aura/root/aura-root.d.ts +0 -49
- package/dist/aura/root/aura-root.js +2 -16
- package/dist/element-events.generated.js +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/strands/index.d.ts +2 -0
- package/dist/strands/index.js +2 -0
- package/dist/strands/palette.d.ts +42 -0
- package/dist/strands/palette.js +24 -0
- package/dist/strands/path.d.ts +89 -0
- package/dist/strands/path.js +153 -0
- package/dist/strands/renderer.d.ts +84 -0
- package/dist/strands/renderer.js +255 -0
- package/dist/strands/root/strands-root.css.d.ts +1 -0
- package/dist/strands/root/strands-root.css.js +8 -0
- package/dist/strands/root/strands-root.d.ts +230 -0
- package/dist/strands/root/strands-root.js +466 -0
- package/dist/strands/shader.d.ts +22 -0
- package/dist/strands/shader.js +198 -0
- package/dist/strands/stop/strands-stop.css.d.ts +1 -0
- package/dist/strands/stop/strands-stop.css.js +2 -0
- package/dist/strands/stop/strands-stop.d.ts +44 -0
- package/dist/strands/stop/strands-stop.js +29 -0
- package/lint.json +1 -1
- package/package.json +6 -6
- package/types/jsx.d.ts +496 -0
- package/types/svelte.d.ts +2 -0
- package/types/vue.d.ts +81 -0
package/types/vue.d.ts
CHANGED
|
@@ -127,6 +127,8 @@ import type {
|
|
|
127
127
|
HelixStat,
|
|
128
128
|
HelixSteps,
|
|
129
129
|
HelixStep,
|
|
130
|
+
HelixStrands,
|
|
131
|
+
HelixStrandsStop,
|
|
130
132
|
HelixSwitch,
|
|
131
133
|
HelixTableCell,
|
|
132
134
|
HelixTableColumn,
|
|
@@ -244,6 +246,7 @@ import type {
|
|
|
244
246
|
HelixBeforeResizeEvent,
|
|
245
247
|
HelixCollapseEvent,
|
|
246
248
|
HelixResizedEvent,
|
|
249
|
+
HelixStrandsFallbackEvent,
|
|
247
250
|
HelixLoadEvent,
|
|
248
251
|
HelixTourAskEvent,
|
|
249
252
|
HelixTourStatusEvent,
|
|
@@ -16651,6 +16654,64 @@ export type HelixStepVueEvents = {
|
|
|
16651
16654
|
"helix-select": HelixStepHelixSelectElementEvent;
|
|
16652
16655
|
};
|
|
16653
16656
|
|
|
16657
|
+
/** `HelixStrands` component event */
|
|
16658
|
+
export type HelixStrandsElementEvent<E = Event> = TypedEvent<HelixStrands, E>;
|
|
16659
|
+
/** `helix-strands-fallback` event type */
|
|
16660
|
+
export type HelixStrandsHelixStrandsFallbackElementEvent =
|
|
16661
|
+
HelixStrandsElementEvent<HelixStrandsFallbackEvent>;
|
|
16662
|
+
|
|
16663
|
+
export type HelixStrandsVueProps = {
|
|
16664
|
+
/** Where the form sits across the box, as a share of the width: the fan's
|
|
16665
|
+
bend or the ribbon's axis. `0` is the left edge and `1` the right. A wave
|
|
16666
|
+
crosses the whole width and does not read it. Unset, a fan bends at `0.4`
|
|
16667
|
+
and a ribbon runs down the middle.
|
|
16668
|
+
|
|
16669
|
+
**A share rather than a length**, so the ribbon keeps its place when the
|
|
16670
|
+
box changes shape. Read inside a box only; in `travel` each stop has its
|
|
16671
|
+
own. */
|
|
16672
|
+
at?: (HelixStrands["at"]) | undefined;
|
|
16673
|
+
/** How many strands the ribbon has, from `0`, sixty, to `1`, three hundred and
|
|
16674
|
+
forty. Clamped to that range. */
|
|
16675
|
+
density?: (HelixStrands["density"]) | undefined;
|
|
16676
|
+
/** Overall brightness, as a multiplier on the light. */
|
|
16677
|
+
gain?: (HelixStrands["gain"]) | undefined;
|
|
16678
|
+
/** The share of strands drawn out of focus where the ribbon is wide, from `0`,
|
|
16679
|
+
every strand sharp, to `1`, every one soft. Clamped to that range. A tight
|
|
16680
|
+
form, such as a fan's bend or a wave, stays sharp whatever this says. */
|
|
16681
|
+
softness?: (HelixStrands["softness"]) | undefined;
|
|
16682
|
+
/** How fast the ribbon moves, as a multiplier on time. `0` holds it still. */
|
|
16683
|
+
speed?: (HelixStrands["speed"]) | undefined;
|
|
16684
|
+
/** How wide the ribbon is, as a multiplier on each form's own width. */
|
|
16685
|
+
spread?: (HelixStrands["spread"]) | undefined;
|
|
16686
|
+
/** Whether the ribbon is laid down the whole page, so scrolling travels along
|
|
16687
|
+
it.
|
|
16688
|
+
|
|
16689
|
+
Reflected because the stylesheet selects on it: in `travel` the host fixes
|
|
16690
|
+
itself to the viewport, behind the page. */
|
|
16691
|
+
travel?: (HelixStrands["travel"]) | undefined;
|
|
16692
|
+
/** The form the ribbon takes. When it is not set, the form is `ribbon`. In
|
|
16693
|
+
`travel`, the form of every stretch no stop claims. */
|
|
16694
|
+
variant?: (HelixStrands["variant"]) | undefined;
|
|
16695
|
+
};
|
|
16696
|
+
|
|
16697
|
+
export type HelixStrandsVueEvents = {
|
|
16698
|
+
/** Fired each time the element stops drawing its ribbon and shows its gradient, with the reason. */
|
|
16699
|
+
"helix-strands-fallback": HelixStrandsHelixStrandsFallbackElementEvent;
|
|
16700
|
+
};
|
|
16701
|
+
|
|
16702
|
+
export type HelixStrandsStopVueProps = {
|
|
16703
|
+
/** Where the form sits across the page, as a share of the width: the fan's
|
|
16704
|
+
bend or the ribbon's axis. A wave crosses the whole width and does not
|
|
16705
|
+
read it. Unset, a fan bends at `0.4` and a ribbon runs down the middle. */
|
|
16706
|
+
at?: (HelixStrandsStop["at"]) | undefined;
|
|
16707
|
+
/** The id of the element the form is pinned to, in the same tree as the stop. */
|
|
16708
|
+
for?: (HelixStrandsStop["for"]) | undefined;
|
|
16709
|
+
/** The form the ribbon takes at the element. When it is not set, the form is `ribbon`. */
|
|
16710
|
+
variant?: (HelixStrandsStop["variant"]) | undefined;
|
|
16711
|
+
};
|
|
16712
|
+
|
|
16713
|
+
export type HelixStrandsStopVueEvents = {};
|
|
16714
|
+
|
|
16654
16715
|
/** `HelixSwitch` component event */
|
|
16655
16716
|
export type HelixSwitchElementEvent<E = Event> = TypedEvent<HelixSwitch, E>;
|
|
16656
16717
|
/** `helix-before-toggle` event type */
|
|
@@ -22781,6 +22842,14 @@ export type CustomCssProperties = {
|
|
|
22781
22842
|
"--steps-progress-track-color"?: (string) | undefined;
|
|
22782
22843
|
/** How far through the sequence is, as a percentage, written on the `progress` part. */
|
|
22783
22844
|
"--steps-progress"?: (string) | undefined;
|
|
22845
|
+
/** The color of most strands. Defaults to `--helix-color-primary`. */
|
|
22846
|
+
"--strands-glow"?: (string) | undefined;
|
|
22847
|
+
/** The page the light is added to. Defaults to `--helix-color-background`. */
|
|
22848
|
+
"--strands-ground"?: (string) | undefined;
|
|
22849
|
+
/** The hottest strands, and on a light page the ink the light darkens toward. Defaults to `--helix-color-primary-hover` on a dark page and `--helix-color-primary-active` on a light one. */
|
|
22850
|
+
"--strands-peak"?: (string) | undefined;
|
|
22851
|
+
/** The color of a few strands, for depth. Defaults to `--helix-color-info`. */
|
|
22852
|
+
"--strands-tint"?: (string) | undefined;
|
|
22784
22853
|
/** Height of the track. The width follows it. */
|
|
22785
22854
|
"--switch-block-size"?: (string) | undefined;
|
|
22786
22855
|
/** Color of the icon on the thumb. Without it, the icon is muted while off and takes the on color while on. */
|
|
@@ -24023,6 +24092,18 @@ export interface WcToolkitVueGlobalComponents {
|
|
|
24023
24092
|
HelixStepVueProps,
|
|
24024
24093
|
HelixStepVueEvents
|
|
24025
24094
|
>;
|
|
24095
|
+
/** Hundreds of thin strands are drawn as one ribbon, and the light they add together is bloomed, so where they converge the ribbon burns hot. The ribbon moves on its own all the time: it sways and breathes, its strands wave and roll over one another, and light runs along them. Its palette comes from the tokens. The strands are '--helix-color-primary', a few are '--helix-color-info' for depth, and the page they light is '--helix-color-background'. On a light page the light becomes ink, because light added to near-white cannot be seen. **Three forms, set with 'variant'.** 'fan' is a tight, bright bend with its arms opening to the right. 'ribbon', the default, is a broad, soft ribbon in long curves. 'waves' is sharp strands crossing the full width. **In its own box, by default.** The element fills the box it is given, the way an image does, and 'at' places the fan's bend or the ribbon's axis across it. Content placed inside sits over the ribbon, in the 'content' part. **Down the whole page, with 'travel'.** The element fixes itself behind the page, on '--helix-layer-beneath', and lays one ribbon from the top of the page to the bottom, so scrolling travels along it. Put 'helix-strands-stop' elements inside to pin a form to a section: each names an element with 'for' and says which form the ribbon takes there. Between stops the ribbon fills the gap in its own 'variant', and between two waves it turns off screen so each wave reads alone. Set 'z-index' on the element to move it. The ribbon stops moving in these cases: - 'prefers-reduced-motion' is set. The element shows one still frame, and in 'travel' still follows the scroll, without easing. - The element is off screen or in a background tab. It shows a gradient from the same tokens in these cases, and matches ':state(fallback)' and sends 'helix-strands-fallback' with the reason: - The renderer draws on the CPU, such as a headless browser or a machine with no usable GPU. - There is no WebGL, or the browser took the drawing context back. Strands is styled only and has behavior, as 'Aura' does: its behavior is drawing to a canvas, so there is no structure for a headless version to hold. */
|
|
24096
|
+
"helix-strands": DefineCustomElement<
|
|
24097
|
+
HelixStrands,
|
|
24098
|
+
HelixStrandsVueProps,
|
|
24099
|
+
HelixStrandsVueEvents
|
|
24100
|
+
>;
|
|
24101
|
+
/** Placed inside a 'helix-strands' with 'travel', a stop names an element with 'for' and says which form the ribbon takes when the page reaches it: a 'fan' bending through it, a 'ribbon' passing through 'at', or 'waves' crossing at its top edge. The stops are read in page order, whatever order they are written in, and a stop naming no element is skipped. A stop draws nothing itself and is never shown. **Every property is reflected**, because the parent watches its stops' attributes to lay the ribbon out again: a change made from script reaches the page as a change made in markup does. None has a default, so a stop writes nothing it was not given. */
|
|
24102
|
+
"helix-strands-stop": DefineCustomElement<
|
|
24103
|
+
HelixStrandsStop,
|
|
24104
|
+
HelixStrandsStopVueProps,
|
|
24105
|
+
HelixStrandsStopVueEvents
|
|
24106
|
+
>;
|
|
24026
24107
|
/** A thumb moves along a track. The switch is the one place in Helix where color means "on". A checkbox has a tick, and a switch has no mark, so the fill is what tells the two states apart. The input is the hit target. It is stretched over the track and made invisible, so the press, the focus, and the label forwarding come from the platform. The height is '--helix-size-switch', one step above the checkbox's at every density. At the checkbox's height the thumb has two pixels of track around it, and the control looks like a small dash. The width follows the height, so setting '--switch-block-size' widens the switch too and keeps the proportion. The thumb is an element, the 'thumb' part, and holds an icon for each state: one in the 'on' slot shows while the switch is on, and one in the 'off' slot while it is off. */
|
|
24027
24108
|
"helix-switch": DefineCustomElement<
|
|
24028
24109
|
HelixSwitch,
|