@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.
@@ -0,0 +1,2 @@
1
+ import { createSheet } from '@fusion.dev/helix-core';
2
+ export const styles = createSheet(`:host {display: none;}@media print {:host {display: none;}}`);
@@ -0,0 +1,44 @@
1
+ import { HelixElement } from '@fusion.dev/helix-core';
2
+ import type { CSSResultGroup } from 'lit';
3
+ import { nothing } from 'lit';
4
+ import type { StrandsVariant } from '../path.js';
5
+ /**
6
+ * @summary Pins a form of the ribbon to a section of the page.
7
+ *
8
+ * @description
9
+ * Placed inside a `helix-strands` with `travel`, a stop names an element with
10
+ * `for` and says which form the ribbon takes when the page reaches it: a `fan`
11
+ * bending through it, a `ribbon` passing through `at`, or `waves` crossing at
12
+ * its top edge. The stops are read in page order, whatever order they are
13
+ * written in, and a stop naming no element is skipped.
14
+ *
15
+ * A stop draws nothing itself and is never shown.
16
+ *
17
+ * **Every property is reflected**, because the parent watches its stops'
18
+ * attributes to lay the ribbon out again: a change made from script reaches the
19
+ * page as a change made in markup does. None has a default, so a stop writes
20
+ * nothing it was not given.
21
+ *
22
+ * @since 0.147.0
23
+ * @status experimental
24
+ * @documentation https://fusion.dev/helix/components/strands
25
+ */
26
+ export declare class HelixStrandsStop extends HelixElement {
27
+ static styles: CSSResultGroup;
28
+ /**
29
+ * Where the form sits across the page, as a share of the width: the fan's
30
+ * bend or the ribbon's axis. A wave crosses the whole width and does not
31
+ * read it. Unset, a fan bends at `0.4` and a ribbon runs down the middle.
32
+ */
33
+ at?: number;
34
+ /** The id of the element the form is pinned to, in the same tree as the stop. */
35
+ for?: string;
36
+ /** The form the ribbon takes at the element. When it is not set, the form is `ribbon`. */
37
+ variant?: StrandsVariant;
38
+ protected render(): typeof nothing;
39
+ }
40
+ declare global {
41
+ interface HTMLElementTagNameMap {
42
+ 'helix-strands-stop': HelixStrandsStop;
43
+ }
44
+ }
@@ -0,0 +1,29 @@
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 { customElement, HelixElement } from '@fusion.dev/helix-core';
8
+ import { nothing } from 'lit';
9
+ import { property } from 'lit/decorators.js';
10
+ import { styles } from './strands-stop.css.js';
11
+ let HelixStrandsStop = class HelixStrandsStop extends HelixElement {
12
+ static { this.styles = styles; }
13
+ render() {
14
+ return nothing;
15
+ }
16
+ };
17
+ __decorate([
18
+ property({ reflect: true, type: Number })
19
+ ], HelixStrandsStop.prototype, "at", void 0);
20
+ __decorate([
21
+ property({ reflect: true })
22
+ ], HelixStrandsStop.prototype, "for", void 0);
23
+ __decorate([
24
+ property({ reflect: true })
25
+ ], HelixStrandsStop.prototype, "variant", void 0);
26
+ HelixStrandsStop = __decorate([
27
+ customElement('helix-strands-stop')
28
+ ], HelixStrandsStop);
29
+ export { HelixStrandsStop };