ember-primitives 0.26.0 → 0.26.2

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.
@@ -1,61 +1,6 @@
1
1
  import './styles.css';
2
2
  import Component from '@glimmer/component';
3
- type ScrollBehavior = 'auto' | 'smooth' | 'instant';
4
- export interface Signature {
5
- Args: {
6
- /**
7
- * The distance in pixels between each item in the slider.
8
- */
9
- gap?: number;
10
- /**
11
- * The distance from the edge of the container to the first and last item, this allows
12
- * the contents to visually overflow the container
13
- */
14
- offset?: number;
15
- /**
16
- * The scroll behavior to use when scrolling the slider. Defaults to smooth.
17
- */
18
- scrollBehavior?: ScrollBehavior;
19
- };
20
- Blocks: {
21
- /**
22
- * The header block is where the header content is placed.
23
- */
24
- header: [];
25
- /**
26
- * The content block is where the items that will be scrolled are placed.
27
- */
28
- content: [];
29
- /**
30
- * The controls block is where the left and right buttons are placed.
31
- */
32
- controls: [
33
- {
34
- /**
35
- * Whether the slider can scroll.
36
- */
37
- canScroll: boolean;
38
- /**
39
- * Whether the slider cannot scroll left.
40
- */
41
- cannotScrollLeft: boolean;
42
- /**
43
- * Whether the slider cannot scroll right.
44
- */
45
- cannotScrollRight: boolean;
46
- /**
47
- * The function to scroll the slider left.
48
- */
49
- scrollLeft: () => void;
50
- /**
51
- * The function to scroll the slider right.
52
- */
53
- scrollRight: () => void;
54
- }
55
- ];
56
- };
57
- Element: HTMLElement;
58
- }
3
+ import type { ScrollBehavior, Signature } from './types.ts';
59
4
  export declare class Zoetrope extends Component<Signature> {
60
5
  scrollerElement: HTMLElement | null;
61
6
  currentlyScrolled: number;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/zoetrope/index.ts"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAC;AAEtB,OAAO,SAAS,MAAM,oBAAoB,CAAC;AAS3C,KAAK,cAAc,GAAG,MAAM,GAAG,QAAQ,GAAG,SAAS,CAAC;AA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{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/zoetrope/index.ts"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAC;AAEtB,OAAO,SAAS,MAAM,oBAAoB,CAAC;AAS3C,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAM5D,qBAAa,QAAS,SAAQ,SAAS,CAAC,SAAS,CAAC;IACvC,eAAe,EAAE,WAAW,GAAG,IAAI,CAAQ;IAC3C,iBAAiB,SAAK;IACtB,WAAW,SAAK;IAChB,WAAW,SAAK;IAEzB,OAAO,CAAC,eAAe,CAKrB;IAEF,cAAc,UAA2B;IACzC,cAAc,aAEZ;IAEF,OAAO,CAAC,iBAAiB,CAwBtB;IAEH,OAAO,CAAC,WAAW,CAyCjB;IAEF,OAAO,CAAC,cAAc,CAEpB;IAEF,IAAI,MAAM,WAET;IAED,IAAI,GAAG,WAEN;IAED,IAAI,SAAS,YAEZ;IAED,IAAI,gBAAgB,YAEnB;IAED,IAAI,iBAAiB,YAEpB;IAED,IAAI,cAAc,IAAI,cAAc,CAMnC;IAED,UAAU,aA0CR;IAEF,WAAW,aAgCT;IAEF,OAAO,CAAC,sBAAsB;CA0H/B;AAED,eAAe,QAAQ,CAAC"}
@@ -0,0 +1,57 @@
1
+ export type ScrollBehavior = 'auto' | 'smooth' | 'instant';
2
+ export interface Signature {
3
+ Args: {
4
+ /**
5
+ * The distance in pixels between each item in the slider.
6
+ */
7
+ gap?: number;
8
+ /**
9
+ * The distance from the edge of the container to the first and last item, this allows
10
+ * the contents to visually overflow the container
11
+ */
12
+ offset?: number;
13
+ /**
14
+ * The scroll behavior to use when scrolling the slider. Defaults to smooth.
15
+ */
16
+ scrollBehavior?: ScrollBehavior;
17
+ };
18
+ Blocks: {
19
+ /**
20
+ * The header block is where the header content is placed.
21
+ */
22
+ header: [];
23
+ /**
24
+ * The content block is where the items that will be scrolled are placed.
25
+ */
26
+ content: [];
27
+ /**
28
+ * The controls block is where the left and right buttons are placed.
29
+ */
30
+ controls: [
31
+ {
32
+ /**
33
+ * Whether the slider can scroll.
34
+ */
35
+ canScroll: boolean;
36
+ /**
37
+ * Whether the slider cannot scroll left.
38
+ */
39
+ cannotScrollLeft: boolean;
40
+ /**
41
+ * Whether the slider cannot scroll right.
42
+ */
43
+ cannotScrollRight: boolean;
44
+ /**
45
+ * The function to scroll the slider left.
46
+ */
47
+ scrollLeft: () => void;
48
+ /**
49
+ * The function to scroll the slider right.
50
+ */
51
+ scrollRight: () => void;
52
+ }
53
+ ];
54
+ };
55
+ Element: HTMLElement;
56
+ }
57
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/components/zoetrope/types.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,cAAc,GAAG,MAAM,GAAG,QAAQ,GAAG,SAAS,CAAC;AAE3D,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE;QACJ;;WAEG;QACH,GAAG,CAAC,EAAE,MAAM,CAAC;QAEb;;;WAGG;QACH,MAAM,CAAC,EAAE,MAAM,CAAC;QAEhB;;WAEG;QACH,cAAc,CAAC,EAAE,cAAc,CAAC;KACjC,CAAC;IACF,MAAM,EAAE;QACN;;WAEG;QACH,MAAM,EAAE,EAAE,CAAC;QAEX;;WAEG;QACH,OAAO,EAAE,EAAE,CAAC;QAEZ;;WAEG;QACH,QAAQ,EAAE;YACR;gBACE;;mBAEG;gBACH,SAAS,EAAE,OAAO,CAAC;gBAEnB;;mBAEG;gBACH,gBAAgB,EAAE,OAAO,CAAC;gBAE1B;;mBAEG;gBACH,iBAAiB,EAAE,OAAO,CAAC;gBAE3B;;mBAEG;gBACH,UAAU,EAAE,MAAM,IAAI,CAAC;gBAEvB;;mBAEG;gBACH,WAAW,EAAE,MAAM,IAAI,CAAC;aACzB;SACF,CAAC;KACH,CAAC;IACF,OAAO,EAAE,WAAW,CAAC;CACtB"}
@@ -1,2 +1,4 @@
1
1
  export { Zoetrope } from "./zoetrope/index";
2
+ export { default } from "./zoetrope/index";
3
+ export type { Signature } from './zoetrope/types.ts';
2
4
  //# sourceMappingURL=zoetrope.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"zoetrope.d.ts","sourceRoot":"","sources":["../../src/components/zoetrope.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC"}
1
+ {"version":3,"file":"zoetrope.d.ts","sourceRoot":"","sources":["../../src/components/zoetrope.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAChD,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAC/C,YAAY,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAC"}
@@ -18,7 +18,7 @@ export { Shadowed } from "./components/shadowed";
18
18
  export { Switch } from "./components/switch";
19
19
  export { Toggle } from "./components/toggle";
20
20
  export { ToggleGroup } from "./components/toggle-group";
21
- export { Zoetrope } from "./components/zoetrope/index";
21
+ export { Zoetrope } from './components/zoetrope.ts';
22
22
  export * from './helpers.ts';
23
23
  export type { default as SetupService } from './services/ember-primitives/setup.ts';
24
24
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,SAAS,EAAE,MAAM,4BAA4B,CAAC;AACvD,YAAY,EACV,iCAAiC,EACjC,gCAAgC,EAChC,8BAA8B,EAC9B,iCAAiC,GAClC,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAC;AACjD,OAAO,EAAE,MAAM,EAAE,MAAM,IAAI,KAAK,EAAE,MAAM,yBAAyB,CAAC;AAClE,OAAO,EAAE,YAAY,EAAE,MAAM,gCAAgC,CAAC;AAC9D,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,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E,OAAO,EAAE,YAAY,EAAE,MAAM,gCAAgC,CAAC;AAC9D,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAC7C,OAAO,EAAE,YAAY,EAAE,MAAM,uCAAuC,CAAC;AACrE,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAC7C,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAC7C,OAAO,EAAE,GAAG,EAAE,QAAQ,EAAE,MAAM,0CAA0C,CAAC;AACzE,OAAO,EAAE,OAAO,EAAE,MAAM,0BAA0B,CAAC;AACnD,OAAO,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAC;AACjD,OAAO,EAAE,aAAa,EAAE,MAAM,iCAAiC,CAAC;AAChE,OAAO,EAAE,OAAO,IAAI,OAAO,EAAE,MAAM,iCAAiC,CAAC;AACrE,OAAO,EAAE,QAAQ,EAAE,MAAM,2BAA2B,CAAC;AACrD,OAAO,EAAE,QAAQ,EAAE,MAAM,2BAA2B,CAAC;AACrD,OAAO,EAAE,QAAQ,EAAE,MAAM,2BAA2B,CAAC;AACrD,OAAO,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAC;AACjD,OAAO,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAC;AACjD,OAAO,EAAE,WAAW,EAAE,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AACpD,cAAc,cAAc,CAAC;AAC7B,YAAY,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,sCAAsC,CAAC"}
@@ -0,0 +1,2 @@
1
+
2
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +1,2 @@
1
- export { Zoetrope } from './zoetrope/index.js';
1
+ export { Zoetrope, Zoetrope as default } from './zoetrope/index.js';
2
2
  //# sourceMappingURL=zoetrope.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../src/index.ts"],"sourcesContent":["/**\n * DANGER: this is a *barrel file*\n *\n * It forces the whole library to be loaded and all dependencies.\n *\n * If you have a small app, you probably don't want to import from here -- instead import from each sub-path.\n */\nimport { importSync, isDevelopingApp, macroCondition } from '@embroider/macros';\n\nif (macroCondition(isDevelopingApp())) {\n importSync('./components/violations.css');\n}\n\nexport { Accordion } from './components/accordion.gts';\nexport type {\n AccordionContentExternalSignature,\n AccordionHeaderExternalSignature,\n AccordionItemExternalSignature,\n AccordionTriggerExternalSignature,\n} from './components/accordion/public.ts';\nexport { Avatar } from './components/avatar.gts';\nexport { Dialog, Dialog as Modal } from './components/dialog.gts';\nexport { ExternalLink } from './components/external-link.gts';\nexport { Form } from './components/form.gts';\nexport { StickyFooter } from './components/layout/sticky-footer.gts';\nexport { Link } from './components/link.gts';\nexport { Menu } from './components/menu.gts';\nexport { OTP, OTPInput } from './components/one-time-password/index.gts';\nexport { Popover } from './components/popover.gts';\nexport { Portal } from './components/portal.gts';\nexport { PortalTargets } from './components/portal-targets.gts';\nexport { TARGETS as PORTALS } from './components/portal-targets.gts';\nexport { Progress } from './components/progress.gts';\nexport { Scroller } from './components/scroller.gts';\nexport { Shadowed } from './components/shadowed.gts';\nexport { Switch } from './components/switch.gts';\nexport { Toggle } from './components/toggle.gts';\nexport { ToggleGroup } from './components/toggle-group.gts';\nexport { Zoetrope } from './components/zoetrope/index.gts';\nexport * from './helpers.ts';\nexport type { default as SetupService } from './services/ember-primitives/setup.ts';\n"],"names":["macroCondition","isDevelopingApp","importSync"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AAGA,IAAIA,cAAc,CAACC,eAAe,EAAE,CAAC,EAAE;EACrCC,UAAU,CAAC,6BAA6B,CAAC,CAAA;AAC3C"}
1
+ {"version":3,"file":"index.js","sources":["../src/index.ts"],"sourcesContent":["/**\n * DANGER: this is a *barrel file*\n *\n * It forces the whole library to be loaded and all dependencies.\n *\n * If you have a small app, you probably don't want to import from here -- instead import from each sub-path.\n */\nimport { importSync, isDevelopingApp, macroCondition } from '@embroider/macros';\n\nif (macroCondition(isDevelopingApp())) {\n importSync('./components/violations.css');\n}\n\nexport { Accordion } from './components/accordion.gts';\nexport type {\n AccordionContentExternalSignature,\n AccordionHeaderExternalSignature,\n AccordionItemExternalSignature,\n AccordionTriggerExternalSignature,\n} from './components/accordion/public.ts';\nexport { Avatar } from './components/avatar.gts';\nexport { Dialog, Dialog as Modal } from './components/dialog.gts';\nexport { ExternalLink } from './components/external-link.gts';\nexport { Form } from './components/form.gts';\nexport { StickyFooter } from './components/layout/sticky-footer.gts';\nexport { Link } from './components/link.gts';\nexport { Menu } from './components/menu.gts';\nexport { OTP, OTPInput } from './components/one-time-password/index.gts';\nexport { Popover } from './components/popover.gts';\nexport { Portal } from './components/portal.gts';\nexport { PortalTargets } from './components/portal-targets.gts';\nexport { TARGETS as PORTALS } from './components/portal-targets.gts';\nexport { Progress } from './components/progress.gts';\nexport { Scroller } from './components/scroller.gts';\nexport { Shadowed } from './components/shadowed.gts';\nexport { Switch } from './components/switch.gts';\nexport { Toggle } from './components/toggle.gts';\nexport { ToggleGroup } from './components/toggle-group.gts';\nexport { Zoetrope } from './components/zoetrope.ts';\nexport * from './helpers.ts';\nexport type { default as SetupService } from './services/ember-primitives/setup.ts';\n"],"names":["macroCondition","isDevelopingApp","importSync"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AAGA,IAAIA,cAAc,CAACC,eAAe,EAAE,CAAC,EAAE;EACrCC,UAAU,CAAC,6BAA6B,CAAC,CAAA;AAC3C"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ember-primitives",
3
- "version": "0.26.0",
3
+ "version": "0.26.2",
4
4
  "description": "Making apps easier to build",
5
5
  "sideEffects": [
6
6
  "*.css"
@@ -134,7 +134,7 @@
134
134
  "@glint/template": ">= 1.0.0",
135
135
  "ember-modifier": ">= 4.1.0",
136
136
  "ember-resources": ">= 6.1.0",
137
- "ember-source": "^5.12.0"
137
+ "ember-source": ">= 4.12.0"
138
138
  },
139
139
  "peerDependenciesMeta": {
140
140
  "@ember/test-helpers": {