@jumpgroup/jump-design-system 0.2.2 → 0.2.4
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/dist/cjs/{index-79e97f36.js → index-41aaa52a.js} +181 -11
- package/dist/cjs/index-41aaa52a.js.map +1 -0
- package/dist/cjs/jump-badge.cjs.entry.js +6 -6
- package/dist/cjs/jump-badge.cjs.entry.js.map +1 -1
- package/dist/cjs/jump-button.cjs.entry.js +10 -6
- package/dist/cjs/jump-button.cjs.entry.js.map +1 -1
- package/dist/cjs/jump-card.cjs.entry.js +4 -4
- package/dist/cjs/jump-card.cjs.entry.js.map +1 -1
- package/dist/cjs/jump-design-system.cjs.js +3 -3
- package/dist/cjs/jump-design-system.cjs.js.map +1 -1
- package/dist/cjs/jump-icon.cjs.entry.js +5 -5
- package/dist/cjs/jump-icon.cjs.entry.js.map +1 -1
- package/dist/cjs/jump-pagination.cjs.entry.js +32 -10
- package/dist/cjs/jump-pagination.cjs.entry.js.map +1 -1
- package/dist/cjs/jump-tab.cjs.entry.js +29 -0
- package/dist/cjs/jump-tab.cjs.entry.js.map +1 -0
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +5 -4
- package/dist/collection/components/jump-badge/jump-badge.css +1 -1
- package/dist/collection/components/jump-badge/jump-badge.js +4 -4
- package/dist/collection/components/jump-badge/jump-badge.js.map +1 -1
- package/dist/collection/components/jump-badge/test/jump-badge.spec.js +2 -2
- package/dist/collection/components/jump-badge/test/jump-badge.spec.js.map +1 -1
- package/dist/collection/components/jump-button/jump-button-anchor.stories.js +87 -0
- package/dist/collection/components/jump-button/jump-button-anchor.stories.js.map +1 -0
- package/dist/collection/components/jump-button/jump-button-dimension.stories.js +74 -0
- package/dist/collection/components/jump-button/jump-button-dimension.stories.js.map +1 -0
- package/dist/collection/components/jump-button/jump-button-filled.stories.js +14 -482
- package/dist/collection/components/jump-button/jump-button-filled.stories.js.map +1 -1
- package/dist/collection/components/jump-button/jump-button-only-icon.stories.js +109 -0
- package/dist/collection/components/jump-button/jump-button-only-icon.stories.js.map +1 -0
- package/dist/collection/components/jump-button/jump-button-outline.stories.js +20 -285
- package/dist/collection/components/jump-button/jump-button-outline.stories.js.map +1 -1
- package/dist/collection/components/jump-button/jump-button-text.stories.js +83 -0
- package/dist/collection/components/jump-button/jump-button-text.stories.js.map +1 -0
- package/dist/collection/components/jump-button/jump-button.css +103 -50
- package/dist/collection/components/jump-button/jump-button.js +41 -19
- package/dist/collection/components/jump-button/jump-button.js.map +1 -1
- package/dist/collection/components/jump-button/test/jump-button.spec.js +2 -2
- package/dist/collection/components/jump-button/test/jump-button.spec.js.map +1 -1
- package/dist/collection/components/jump-card/jump-card-border-radius.stories.js +2 -14
- package/dist/collection/components/jump-card/jump-card-border-radius.stories.js.map +1 -1
- package/dist/collection/components/jump-card/jump-card-top-border-content-radius.stories.js +1 -2
- package/dist/collection/components/jump-card/jump-card-top-border-content-radius.stories.js.map +1 -1
- package/dist/collection/components/jump-card/jump-card.css +50 -1
- package/dist/collection/components/jump-card/jump-card.js +13 -13
- package/dist/collection/components/jump-card/jump-card.js.map +1 -1
- package/dist/collection/components/{app-icon → jump-icon}/jump-icon.js +2 -2
- package/dist/collection/components/jump-icon/jump-icon.js.map +1 -0
- package/dist/collection/components/{app-icon → jump-icon}/jump-icon.stories.js +1 -1
- package/dist/collection/components/jump-icon/jump-icon.stories.js.map +1 -0
- package/dist/collection/components/jump-icon/test/jump-icon.e2e.js.map +1 -0
- package/dist/collection/components/{app-icon → jump-icon}/test/jump-icon.spec.js +2 -2
- package/dist/collection/components/jump-icon/test/jump-icon.spec.js.map +1 -0
- package/dist/collection/components/jump-pagination/jump-pagination-pages.stories.js +41 -24
- package/dist/collection/components/jump-pagination/jump-pagination-pages.stories.js.map +1 -1
- package/dist/collection/components/jump-pagination/jump-pagination-products.stories.js +19 -40
- package/dist/collection/components/jump-pagination/jump-pagination-products.stories.js.map +1 -1
- package/dist/collection/components/jump-pagination/jump-pagination.css +13 -0
- package/dist/collection/components/jump-pagination/jump-pagination.js +64 -31
- package/dist/collection/components/jump-pagination/jump-pagination.js.map +1 -1
- package/dist/collection/components/jump-tab/jump-tab-inline.stories.js +28 -0
- package/dist/collection/components/jump-tab/jump-tab-inline.stories.js.map +1 -0
- package/dist/collection/components/jump-tab/jump-tab.css +3 -0
- package/dist/collection/components/jump-tab/jump-tab.js +71 -0
- package/dist/collection/components/jump-tab/jump-tab.js.map +1 -0
- package/dist/collection/components/jump-tab/test/jump-tab.e2e.js +10 -0
- package/dist/collection/components/jump-tab/test/jump-tab.e2e.js.map +1 -0
- package/dist/collection/components/jump-tab/test/jump-tab.spec.js +18 -0
- package/dist/collection/components/jump-tab/test/jump-tab.spec.js.map +1 -0
- package/dist/collection/utils/utils.js +29 -3
- package/dist/collection/utils/utils.js.map +1 -1
- package/dist/components/jump-badge.js +7 -7
- package/dist/components/jump-badge.js.map +1 -1
- package/dist/components/jump-button.js +26 -20
- package/dist/components/jump-button.js.map +1 -1
- package/dist/components/jump-card.js +14 -14
- package/dist/components/jump-card.js.map +1 -1
- package/dist/components/jump-icon.js +2 -2
- package/dist/components/jump-icon2.js +4 -4
- package/dist/components/jump-icon2.js.map +1 -1
- package/dist/components/jump-pagination.js +38 -13
- package/dist/components/jump-pagination.js.map +1 -1
- package/dist/components/jump-tab.d.ts +11 -0
- package/dist/components/jump-tab.js +46 -0
- package/dist/components/jump-tab.js.map +1 -0
- package/dist/esm/{index-7feee8ea.js → index-192aeaf1.js} +181 -12
- package/dist/esm/index-192aeaf1.js.map +1 -0
- package/dist/esm/jump-badge.entry.js +6 -6
- package/dist/esm/jump-badge.entry.js.map +1 -1
- package/dist/esm/jump-button.entry.js +10 -6
- package/dist/esm/jump-button.entry.js.map +1 -1
- package/dist/esm/jump-card.entry.js +4 -4
- package/dist/esm/jump-card.entry.js.map +1 -1
- package/dist/esm/jump-design-system.js +4 -4
- package/dist/esm/jump-design-system.js.map +1 -1
- package/dist/esm/jump-icon.entry.js +5 -5
- package/dist/esm/jump-icon.entry.js.map +1 -1
- package/dist/esm/jump-pagination.entry.js +32 -10
- package/dist/esm/jump-pagination.entry.js.map +1 -1
- package/dist/esm/jump-tab.entry.js +25 -0
- package/dist/esm/jump-tab.entry.js.map +1 -0
- package/dist/esm/loader.js +3 -3
- package/dist/jump-design-system/jump-design-system.esm.js +1 -1
- package/dist/jump-design-system/jump-design-system.esm.js.map +1 -1
- package/dist/jump-design-system/p-20ceb40c.js +3 -0
- package/dist/jump-design-system/p-20ceb40c.js.map +1 -0
- package/dist/jump-design-system/{p-bc02e346.entry.js → p-511d4425.entry.js} +3 -3
- package/dist/jump-design-system/p-511d4425.entry.js.map +1 -0
- package/dist/jump-design-system/p-61729377.entry.js +2 -0
- package/dist/jump-design-system/p-61729377.entry.js.map +1 -0
- package/dist/jump-design-system/p-700b96b4.entry.js +2 -0
- package/dist/jump-design-system/p-700b96b4.entry.js.map +1 -0
- package/dist/jump-design-system/p-87256ed6.entry.js +2 -0
- package/dist/jump-design-system/p-87256ed6.entry.js.map +1 -0
- package/dist/jump-design-system/{p-99238e3f.entry.js → p-8f5caf32.entry.js} +2 -2
- package/dist/jump-design-system/p-8f5caf32.entry.js.map +1 -0
- package/dist/jump-design-system/p-9e47f451.entry.js +2 -0
- package/dist/jump-design-system/p-9e47f451.entry.js.map +1 -0
- package/dist/jump-design-system-elements.json +20 -7
- package/dist/types/components/jump-badge/jump-badge.d.ts +1 -1
- package/dist/types/components/jump-button/jump-button-anchor.stories.d.ts +44 -0
- package/dist/types/components/jump-button/jump-button-dimension.stories.d.ts +43 -0
- package/dist/types/components/jump-button/jump-button-filled.stories.d.ts +1 -120
- package/dist/types/components/jump-button/jump-button-only-icon.stories.d.ts +53 -0
- package/dist/types/components/jump-button/jump-button-outline.stories.d.ts +4 -112
- package/dist/types/components/jump-button/jump-button-text.stories.d.ts +40 -0
- package/dist/types/components/jump-button/jump-button.d.ts +7 -2
- package/dist/types/components/{app-icon → jump-icon}/jump-icon.d.ts +1 -1
- package/dist/types/components/jump-pagination/jump-pagination-pages.stories.d.ts +2 -1
- package/dist/types/components/jump-pagination/jump-pagination-products.stories.d.ts +2 -2
- package/dist/types/components/jump-pagination/jump-pagination.d.ts +10 -8
- package/dist/types/components/jump-tab/jump-tab-inline.stories.d.ts +18 -0
- package/dist/types/components/jump-tab/jump-tab.d.ts +6 -0
- package/dist/types/components.d.ts +47 -14
- package/dist/types/utils/utils.d.ts +2 -1
- package/package.json +3 -2
- package/dist/cjs/index-79e97f36.js.map +0 -1
- package/dist/collection/components/app-icon/jump-icon.js.map +0 -1
- package/dist/collection/components/app-icon/jump-icon.stories.js.map +0 -1
- package/dist/collection/components/app-icon/test/jump-icon.e2e.js.map +0 -1
- package/dist/collection/components/app-icon/test/jump-icon.spec.js.map +0 -1
- package/dist/collection/utils/utils.spec.js +0 -16
- package/dist/collection/utils/utils.spec.js.map +0 -1
- package/dist/esm/index-7feee8ea.js.map +0 -1
- package/dist/jump-design-system/p-7cfed9c6.entry.js +0 -2
- package/dist/jump-design-system/p-7cfed9c6.entry.js.map +0 -1
- package/dist/jump-design-system/p-99238e3f.entry.js.map +0 -1
- package/dist/jump-design-system/p-9fd6e0a0.entry.js +0 -2
- package/dist/jump-design-system/p-9fd6e0a0.entry.js.map +0 -1
- package/dist/jump-design-system/p-bc02e346.entry.js.map +0 -1
- package/dist/jump-design-system/p-c560071a.js +0 -3
- package/dist/jump-design-system/p-c560071a.js.map +0 -1
- package/dist/jump-design-system/p-ddb6c98c.entry.js +0 -2
- package/dist/jump-design-system/p-ddb6c98c.entry.js.map +0 -1
- /package/dist/collection/components/{app-icon → jump-icon}/jump-icon.css +0 -0
- /package/dist/collection/components/{app-icon → jump-icon}/test/jump-icon.e2e.js +0 -0
- /package/dist/types/components/{app-icon → jump-icon}/jump-icon.stories.d.ts +0 -0
|
@@ -2,32 +2,54 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-41aaa52a.js');
|
|
6
6
|
|
|
7
|
-
const jumpPaginationCss = ":host{display:block}.JumpPagination{--pagination-label-color:var(--neutral-grey-secondary);--pagination-arrows-color:var(--neutral-grey-secondary);font-family:var(--ff-primary)}.JumpPagination__Wrapper{display:flex;justify-content:space-between}.JumpPagination__Wrapper .elementsPerPage{display:flex;gap:1rem;align-items:center}.JumpPagination__Wrapper .elementsPerPage label{color:var(--pagination-label-color);font-size:14px;font-weight:normal}.JumpPagination__Wrapper .indicators{font-size:16px;font-weight:normal;display:flex;justify-content:space-between;gap:20px;color:var(--pagination-label-color)}.JumpPagination__Wrapper .indicators .arrow{color:var(--pagination-arrows-color);display:flex;align-items:center;gap:10px}.JumpPagination__Wrapper .indicators .elements{color:var(--pagination-label-color);display:flex;align-items:center;gap:5px}";
|
|
7
|
+
const jumpPaginationCss = ":host{display:block}.JumpPagination{--pagination-label-color:var(--neutral-grey-secondary);--pagination-arrows-color:var(--neutral-grey-secondary);--pagination-arrows-disabled:#CBCBCB;font-family:var(--ff-primary)}.JumpPagination__Wrapper{display:flex;justify-content:space-between}.JumpPagination__Wrapper .elementsPerPage{display:flex;gap:1rem;align-items:center}.JumpPagination__Wrapper .elementsPerPage label{color:var(--pagination-label-color);font-size:14px;font-weight:normal}.JumpPagination__Wrapper .indicators{font-size:16px;font-weight:normal;display:flex;justify-content:space-between;gap:20px;color:var(--pagination-label-color)}.JumpPagination__Wrapper .indicators .arrow{color:var(--pagination-arrows-color);display:flex;align-items:center;gap:10px}.JumpPagination__Wrapper .indicators .arrow button{background-color:transparent;border:none;cursor:pointer;padding:0px;display:flex;align-items:center}.JumpPagination__Wrapper .indicators .arrow button:disabled{cursor:not-allowed;color:var(--pagination-arrows-disabled)}.JumpPagination__Wrapper .indicators .elements{color:var(--pagination-label-color);display:flex;align-items:center;gap:5px}";
|
|
8
8
|
const JumpPaginationStyle0 = jumpPaginationCss;
|
|
9
9
|
|
|
10
10
|
const JumpPagination = class {
|
|
11
11
|
constructor(hostRef) {
|
|
12
12
|
index.registerInstance(this, hostRef);
|
|
13
|
+
this.jumpChangePage = index.createEvent(this, "jump-change-page", 7);
|
|
14
|
+
this.firstPage = 1;
|
|
15
|
+
this.currentPage = undefined;
|
|
13
16
|
this.totalElements = undefined;
|
|
14
17
|
this.pagLabel = 'di';
|
|
15
|
-
this.
|
|
16
|
-
this.lastPage =
|
|
18
|
+
this.initialPage = 1;
|
|
19
|
+
this.lastPage = 10;
|
|
17
20
|
this.labelElementsPerPage = 'Elementi per pagina';
|
|
18
21
|
this.elementsRanges = [10, 20, 60, 100];
|
|
19
|
-
this.firstPage = undefined;
|
|
20
22
|
this.completeVersion = false;
|
|
21
|
-
this.
|
|
23
|
+
this.showFirstAndLast = false;
|
|
24
|
+
}
|
|
25
|
+
watchCurrentPage(newValue, oldValue) {
|
|
26
|
+
let details = {
|
|
27
|
+
currentPage: newValue,
|
|
28
|
+
previousPage: oldValue,
|
|
29
|
+
firstPage: this.firstPage,
|
|
30
|
+
lastPage: this.lastPage,
|
|
31
|
+
direction: newValue > oldValue ? 'next' : 'prev'
|
|
32
|
+
};
|
|
33
|
+
this.jumpChangePage.emit(details);
|
|
34
|
+
}
|
|
35
|
+
/* ---------------------- @LIFECYCLE ------------------------- */
|
|
36
|
+
componentWillLoad() {
|
|
37
|
+
this.currentPage = this.initialPage;
|
|
22
38
|
}
|
|
23
39
|
render() {
|
|
24
40
|
var _a;
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
index.h("
|
|
41
|
+
console.log('completeVersion', this.completeVersion);
|
|
42
|
+
return (index.h(index.Host, { key: '32e300881b3a78d25edf6480e9a8a6594f907c76', class: "JumpPagination" }, index.h("div", { key: '0c4e133e409740331083588fbb046d79c2878ea9', class: "JumpPagination__Wrapper" }, this.completeVersion &&
|
|
43
|
+
index.h("div", { key: '13daa8e819ec294b50823becc7e8d904eff66f32', class: "elementsPerPage" }, index.h("label", { key: '162555e0ebfc295d96d5ba358ec879eba1730746', htmlFor: "elements" }, (_a = this.labelElementsPerPage) !== null && _a !== void 0 ? _a : 'Elements per page'), index.h("select", { key: 'c4e99d784347a67c5616b3ed0ca25934dbdae55f', name: "elements", id: "elements" }, this.elementsRanges.map((range) => (index.h("option", { value: range }, range))))), index.h("div", { key: '5eb516226cf5bcb23e575109371c4f55ca235e04', class: "indicators" }, index.h("div", { key: '58a8655b582e8cdcd9f8c553343d9e407dd66971', class: "elements" }, this.completeVersion ?
|
|
44
|
+
index.h("span", null, index.h("span", null, this.firstPage), " - ", index.h("span", null, this.currentPage), " ", this.pagLabel, " ", index.h("span", null, this.totalElements))
|
|
28
45
|
:
|
|
29
|
-
index.h("span", null, index.h("span", null, this.currentPage), "
|
|
46
|
+
index.h("span", null, index.h("span", null, this.currentPage), " ", this.pagLabel, " ", index.h("span", null, this.lastPage))), index.h("div", { key: '92b5476c223e477532726304c282ed34e1acccc7', class: "arrow" }, this.showFirstAndLast &&
|
|
47
|
+
index.h("button", { key: '740c67ee4f73c5a55a022b2281913d8652deeed2', onClick: () => { this.currentPage = this.firstPage; }, disabled: (this.currentPage === this.firstPage) ? true : false }, " ", index.h("jump-icon", { key: '5a880ea7c01afcc8ae9a4e84934e386e0edab58c', slot: "prefix", name: "chevrons-left" }), " "), index.h("button", { key: '08fe7f7faa6c7645151ec3ea2b4bf4247f082a2d', onClick: () => { this.currentPage--; }, disabled: (this.currentPage === this.firstPage) ? true : false }, " ", index.h("jump-icon", { key: '04a972584533f1272b10c7e9068ce332aef77299', slot: "prefix", name: "chevron-left" }), " "), index.h("button", { key: '0ea012c03b06b587296c9190eece67351579b6e3', onClick: () => { this.currentPage++; }, disabled: (this.currentPage === this.lastPage) ? true : false }, " ", index.h("jump-icon", { key: '155d6a407989f9cc5d38832df8fb98a3505c3113', slot: "prefix", name: "chevron-right" }), " "), this.showFirstAndLast &&
|
|
48
|
+
index.h("button", { key: 'be46c67831f6d732d47e9340aca1a43a650af958', onClick: () => { this.currentPage = this.lastPage; }, disabled: (this.currentPage === this.lastPage) ? true : false }, " ", index.h("jump-icon", { key: 'b04a3d8a8726f945d5639761dde68a300e40f80a', slot: "prefix", name: "chevrons-right" }), " "))))));
|
|
30
49
|
}
|
|
50
|
+
static get watchers() { return {
|
|
51
|
+
"currentPage": ["watchCurrentPage"]
|
|
52
|
+
}; }
|
|
31
53
|
};
|
|
32
54
|
JumpPagination.style = JumpPaginationStyle0;
|
|
33
55
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"jump-pagination.entry.cjs.js","mappings":";;;;;;AAAA,MAAM,iBAAiB,GAAG,
|
|
1
|
+
{"file":"jump-pagination.entry.cjs.js","mappings":";;;;;;AAAA,MAAM,iBAAiB,GAAG,uoCAAuoC,CAAC;AAClqC,6BAAe,iBAAiB;;MCMnB,cAAc;;;;yBAMI,CAAC;;;wBAqBW,IAAI;2BAED,CAAC;wBAEJ,EAAE;oCAKU,qBAAqB;8BAKnB,CAAC,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,GAAG,CAAC;+BAMtB,KAAK;gCAEJ,KAAK;;IAtCxD,gBAAgB,CAAC,QAAgB,EAAE,QAAgB;QACjD,IAAI,OAAO,GAAG;YACZ,WAAW,EAAE,QAAQ;YACrB,YAAY,EAAE,QAAQ;YACtB,SAAS,EAAE,IAAI,CAAC,SAAS;YACzB,QAAQ,EAAE,IAAI,CAAC,QAAQ;YACvB,SAAS,EAAE,QAAQ,GAAG,QAAQ,GAAG,MAAM,GAAG,MAAM;SACjD,CAAC;QAEF,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;KACnC;;IAkCD,iBAAiB;QACf,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC,WAAW,CAAC;KACrC;IAED,MAAM;;QACJ,OAAO,CAAC,GAAG,CAAC,iBAAiB,EAAE,IAAI,CAAC,eAAe,CAAC,CAAC;QACrD,QACEA,QAACC,UAAI,qDAAC,KAAK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wEAAW,IAAI,EAAC,QAAQ,EAAC,IAAI,EAAC,cAAc,GAAa,QAAY,EACvEA,qEACE,OAAO,EAAE,QAAO,IAAI,CAAC,WAAW,EAAE,CAAA,EAAC,EACnC,QAAQ,EAAE,CAAC,IAAI,CAAC,WAAW,KAAK,IAAI,CAAC,QAAQ,IAAI,IAAI,GAAG,KAAK,SAC3DA,wEAAW,IAAI,EAAC,QAAQ,EAAC,IAAI,EAAC,eAAe,GAAa,QAAY,EACzE,IAAI,CAAC,gBAAgB;YACpBA,qEACE,OAAO,EAAE,QAAO,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC,QAAQ,CAAA,EAAC,EACjD,QAAQ,EAAE,CAAC,IAAI,CAAC,WAAW,KAAK,IAAI,CAAC,QAAQ,IAAI,IAAI,GAAG,KAAK,SAC3DA,wEAAW,IAAI,EAAC,QAAQ,EAAC,IAAI,EAAC,gBAAgB,GAAa,QAAY,CAEzE,CACF,CACF,CACD,EACP;KACH;;;;;;;;;","names":["h","Host"],"sources":["src/components/jump-pagination/jump-pagination.scss?tag=jump-pagination","src/components/jump-pagination/jump-pagination.tsx"],"sourcesContent":[":host {\n display: block;\n}\n\n.JumpPagination {\n --pagination-label-color: var(--neutral-grey-secondary);\n --pagination-arrows-color: var(--neutral-grey-secondary);\n --pagination-arrows-disabled: #CBCBCB;\n \n font-family: var(--ff-primary);\n\n &__Wrapper {\n display: flex;\n justify-content: space-between;\n\n .elementsPerPage {\n display: flex;\n gap: 1rem;\n align-items: center;\n\n label {\n color: var(--pagination-label-color);\n font-size: 14px;\n font-weight: normal;\n }\n } \n \n .indicators {\n font-size: 16px;\n font-weight: normal;\n display: flex;\n justify-content: space-between;\n gap: 20px;\n \n color: var(--pagination-label-color);\n\n .arrow {\n color: var(--pagination-arrows-color);\n display: flex;\n align-items: center;\n gap: 10px;\n\n button {\n background-color: transparent;\n border: none;\n cursor: pointer;\n padding: 0px;\n display: flex;\n align-items: center;\n }\n\n button:disabled {\n cursor: not-allowed;\n color: var(--pagination-arrows-disabled); \n \n }\n }\n\n .elements {\n color: var(--pagination-label-color);\n display: flex;\n align-items: center;\n gap: 5px;\n }\n }\n \n }\n \n}","import { Component, Host, State, Event, EventEmitter, Prop, h, Watch } from '@stencil/core';\n\n@Component({\n tag: 'jump-pagination',\n styleUrl: 'jump-pagination.scss',\n shadow: false,\n})\nexport class JumpPagination {\n \n /* ---------------------- @STATE ------------------------- */\n /**\n * Indicates the first page/product of the list\n */\n @State() firstPage: number = 1;\n\n @State() currentPage: number;\n\n @Watch('currentPage')\n watchCurrentPage(newValue: number, oldValue: number) {\n let details = {\n currentPage: newValue,\n previousPage: oldValue,\n firstPage: this.firstPage,\n lastPage: this.lastPage,\n direction: newValue > oldValue ? 'next' : 'prev'\n };\n\n this.jumpChangePage.emit(details);\n }\n\n /* ---------------------- @PROPERTIES ------------------------- */\n\n @Prop({reflect:true}) totalElements: number;\n\n @Prop({reflect:true}) pagLabel: string = 'di'; // Identifica la label testuale di pagination. \n\n @Prop({reflect:true}) initialPage: number = 1;\n\n @Prop({reflect:true}) lastPage: number = 10; \n\n /**\n * Label for the elements per page select\n */\n @Prop({reflect:true}) labelElementsPerPage: string = 'Elementi per pagina';\n\n /**\n * Values for the elements per page select\n */\n @Prop({reflect:true}) elementsRanges: Array<number> = [10, 20, 60, 100];\n\n\n /**\n * If true, the component will show the complete version of the pagination, with elements informations\n */\n @Prop({reflect:true}) completeVersion: boolean = false;\n\n @Prop({reflect:true}) showFirstAndLast: boolean = false;\n\n /* ---------------------- @EVENTS ------------------------- */\n @Event({ eventName: 'jump-change-page' }) jumpChangePage: EventEmitter;\n\n /* ---------------------- @LIFECYCLE ------------------------- */\n componentWillLoad() {\n this.currentPage = this.initialPage;\n }\n\n render() {\n console.log('completeVersion', this.completeVersion);\n return (\n <Host class=\"JumpPagination\">\n <div class=\"JumpPagination__Wrapper\">\n { this.completeVersion && \n <div class=\"elementsPerPage\">\n <label htmlFor=\"elements\">{this.labelElementsPerPage ?? 'Elements per page'}</label>\n <select name=\"elements\" id=\"elements\">\n {this.elementsRanges.map((range) => (\n <option value={range}>{range}</option>\n ))}\n </select>\n </div> \n }\n <div class=\"indicators\"> \n <div class=\"elements\">\n {this.completeVersion ?\n <span>\n <span>{this.firstPage}</span> - <span>{this.currentPage}</span> {this.pagLabel} <span>{this.totalElements}</span>\n </span>\n \n :\n <span>\n <span>{this.currentPage}</span> {this.pagLabel} <span>{this.lastPage}</span>\n </span>\n }\n </div>\n <div class=\"arrow\">\n {this.showFirstAndLast &&\n <button \n onClick={() => {this.currentPage = this.firstPage} }\n disabled={(this.currentPage === this.firstPage) ? true : false}\n > <jump-icon slot=\"prefix\" name=\"chevrons-left\"></jump-icon> </button>\n }\n <button \n onClick={() => {this.currentPage--}} \n disabled={(this.currentPage === this.firstPage) ? true : false}\n > <jump-icon slot=\"prefix\" name=\"chevron-left\"></jump-icon> </button>\n <button \n onClick={() => {this.currentPage++}}\n disabled={(this.currentPage === this.lastPage) ? true : false}\n > <jump-icon slot=\"prefix\" name=\"chevron-right\"></jump-icon> </button>\n {this.showFirstAndLast &&\n <button \n onClick={() => {this.currentPage = this.lastPage}}\n disabled={(this.currentPage === this.lastPage) ? true : false}\n > <jump-icon slot=\"prefix\" name=\"chevrons-right\"></jump-icon> </button> \n }\n </div> \n </div>\n </div>\n </Host>\n );\n }\n\n}\n"],"version":3}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const index = require('./index-41aaa52a.js');
|
|
6
|
+
|
|
7
|
+
const jumpTabCss = ":host{display:block}";
|
|
8
|
+
const JumpTabStyle0 = jumpTabCss;
|
|
9
|
+
|
|
10
|
+
const JumpTab = class {
|
|
11
|
+
constructor(hostRef) {
|
|
12
|
+
index.registerInstance(this, hostRef);
|
|
13
|
+
this.activeTab = undefined;
|
|
14
|
+
this.tabNames = undefined;
|
|
15
|
+
}
|
|
16
|
+
componentWillLoad() {
|
|
17
|
+
console.log('Component is about to be rendered');
|
|
18
|
+
console.log('active', this.activeTab);
|
|
19
|
+
console.log('tabNames', this.tabNames);
|
|
20
|
+
}
|
|
21
|
+
render() {
|
|
22
|
+
return (index.h(index.Host, { key: '08d20c1e157286fd4034790df04c2f7113e57e43', class: "JumpTab" }, (this.tabNames && this.activeTab) && this.tabNames.map((tabName) => (index.h("div", { class: `JumpTab__Tab ${this.activeTab === tabName ? 'active' : ''}` }, tabName)))));
|
|
23
|
+
}
|
|
24
|
+
};
|
|
25
|
+
JumpTab.style = JumpTabStyle0;
|
|
26
|
+
|
|
27
|
+
exports.jump_tab = JumpTab;
|
|
28
|
+
|
|
29
|
+
//# sourceMappingURL=jump-tab.cjs.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"file":"jump-tab.entry.cjs.js","mappings":";;;;;;AAAA,MAAM,UAAU,GAAG,sBAAsB,CAAC;AAC1C,sBAAe,UAAU;;MCMZ,OAAO;;;yBAGU,SAAS;wBACH,SAAS;;IAE3C,iBAAiB;QACf,OAAO,CAAC,GAAG,CAAC,mCAAmC,CAAC,CAAC;QACjD,OAAO,CAAC,GAAG,CAAC,QAAQ,EAAC,IAAI,CAAC,SAAS,CAAC,CAAC;QACrC,OAAO,CAAC,GAAG,CAAC,UAAU,EAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;KACvC;IAED,MAAM;QACJ,QACEA,QAACC,UAAI,qDAAC,KAAK,EAAC,SAAS,IAClB,CAAC,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,SAAS,KAAK,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,OAAO,MAC9DD,iBAAK,KAAK,EAAE,gBAAgB,IAAI,CAAC,SAAS,KAAK,OAAO,GAAG,QAAQ,GAAG,EAAE,EAAE,IACrE,OAAO,CACJ,CACP,CAAC,CACG,EACP;KACH;;;;;;","names":["h","Host"],"sources":["src/components/jump-tab/jump-tab.scss?tag=jump-tab&encapsulation=shadow","src/components/jump-tab/jump-tab.tsx"],"sourcesContent":[":host {\n display: block;\n}\n","import { Component, Host, Prop, h } from '@stencil/core';\n\n@Component({\n tag: 'jump-tab',\n styleUrl: 'jump-tab.scss',\n shadow: true,\n})\nexport class JumpTab {\n\n /* ---------------------- @PROPERTIES ------------------------- */\n @Prop() activeTab: string = undefined;\n @Prop() tabNames: Array<string> = undefined;\n\n componentWillLoad() {\n console.log('Component is about to be rendered');\n console.log('active',this.activeTab);\n console.log('tabNames',this.tabNames);\n }\n\n render() {\n return (\n <Host class=\"JumpTab\">\n {(this.tabNames && this.activeTab) && this.tabNames.map((tabName) => (\n <div class={`JumpTab__Tab ${this.activeTab === tabName ? 'active' : ''}`}>\n {tabName}\n </div>\n ))}\n </Host>\n );\n }\n\n}\n"],"version":3}
|
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -2,13 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-41aaa52a.js');
|
|
6
6
|
const appGlobals = require('./app-globals-3a1e7e63.js');
|
|
7
7
|
|
|
8
8
|
const defineCustomElements = async (win, options) => {
|
|
9
9
|
if (typeof window === 'undefined') return undefined;
|
|
10
10
|
await appGlobals.globalScripts();
|
|
11
|
-
return index.bootstrapLazy([["jump-pagination.cjs",[[0,"jump-pagination",{"totalElements":[514,"total-elements"],"pagLabel":[513,"pag-label"],"
|
|
11
|
+
return index.bootstrapLazy([["jump-pagination.cjs",[[0,"jump-pagination",{"totalElements":[514,"total-elements"],"pagLabel":[513,"pag-label"],"initialPage":[514,"initial-page"],"lastPage":[514,"last-page"],"labelElementsPerPage":[513,"label-elements-per-page"],"elementsRanges":[16],"completeVersion":[516,"complete-version"],"showFirstAndLast":[516,"show-first-and-last"],"firstPage":[32],"currentPage":[32]},null,{"currentPage":["watchCurrentPage"]}]]],["jump-badge.cjs",[[0,"jump-badge",{"label":[1],"variant":[1]}]]],["jump-button.cjs",[[1,"jump-button",{"disabled":[4],"variant":[1],"outline":[4],"size":[1],"full":[4],"pill":[4],"text":[4],"onlyIcon":[4,"only-icon"],"href":[1],"target":[1],"type":[1],"name":[1],"value":[1],"ariaLabel":[1,"aria-label"],"class":[1],"buttonId":[1,"button-id"]}]]],["jump-card.cjs",[[4,"jump-card",{"horizontal":[4],"dark":[4],"shadow":[4],"border":[4],"borderRadius":[4,"border-radius"],"topBorderContentRadius":[4,"top-border-content-radius"],"boxed":[4],"roundedMedia":[4,"rounded-media"],"imgSrc":[1,"img-src"],"imgAlt":[1,"img-alt"],"videoSrc":[1,"video-src"]}]]],["jump-tab.cjs",[[1,"jump-tab",{"activeTab":[1,"active-tab"],"tabNames":[16]}]]],["jump-icon.cjs",[[0,"jump-icon",{"name":[1],"class":[1]}]]]], options);
|
|
12
12
|
};
|
|
13
13
|
|
|
14
14
|
exports.setNonce = index.setNonce;
|
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
{
|
|
2
2
|
"entries": [
|
|
3
|
-
"components/app-icon/jump-icon.js",
|
|
4
3
|
"components/jump-badge/jump-badge.js",
|
|
5
4
|
"components/jump-button/jump-button.js",
|
|
6
5
|
"components/jump-card/jump-card.js",
|
|
7
|
-
"components/jump-
|
|
6
|
+
"components/jump-icon/jump-icon.js",
|
|
7
|
+
"components/jump-pagination/jump-pagination.js",
|
|
8
|
+
"components/jump-tab/jump-tab.js"
|
|
8
9
|
],
|
|
9
10
|
"compiler": {
|
|
10
11
|
"name": "@stencil/core",
|
|
11
|
-
"version": "4.
|
|
12
|
-
"typescriptVersion": "5.4.
|
|
12
|
+
"version": "4.15.0",
|
|
13
|
+
"typescriptVersion": "5.4.4"
|
|
13
14
|
},
|
|
14
15
|
"collections": [],
|
|
15
16
|
"bundles": []
|
|
@@ -8,7 +8,7 @@ jump-badge {
|
|
|
8
8
|
align-items: center;
|
|
9
9
|
justify-content: center;
|
|
10
10
|
font-size: var(--fs-300);
|
|
11
|
-
font-weight: var(--fw-
|
|
11
|
+
font-weight: var(--fw-700);
|
|
12
12
|
line-height: 1;
|
|
13
13
|
border-radius: var(--jump-bafge-border-radius);
|
|
14
14
|
border: solid 1px var(--jump-bafge-border-radius);
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { Host, h } from "@stencil/core";
|
|
2
|
-
export class
|
|
2
|
+
export class AppBadge {
|
|
3
3
|
constructor() {
|
|
4
4
|
this.label = '';
|
|
5
5
|
this.variant = 'primary';
|
|
6
6
|
}
|
|
7
7
|
render() {
|
|
8
|
-
return (h(Host, { key: '
|
|
8
|
+
return (h(Host, { key: '1a0a2b2bf95c1217ca9546b19c4ff6b25ca2a86a', variant: this.variant }, this.label));
|
|
9
9
|
}
|
|
10
10
|
static get is() { return "jump-badge"; }
|
|
11
11
|
static get originalStyleUrls() {
|
|
@@ -35,7 +35,7 @@ export class AppCard {
|
|
|
35
35
|
"text": "Indicates the label of the badge"
|
|
36
36
|
},
|
|
37
37
|
"attribute": "label",
|
|
38
|
-
"reflect":
|
|
38
|
+
"reflect": false,
|
|
39
39
|
"defaultValue": "''"
|
|
40
40
|
},
|
|
41
41
|
"variant": {
|
|
@@ -53,7 +53,7 @@ export class AppCard {
|
|
|
53
53
|
"text": "Indicates the variant of the badge"
|
|
54
54
|
},
|
|
55
55
|
"attribute": "variant",
|
|
56
|
-
"reflect":
|
|
56
|
+
"reflect": false,
|
|
57
57
|
"defaultValue": "'primary'"
|
|
58
58
|
}
|
|
59
59
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"jump-badge.js","sourceRoot":"","sources":["../../../src/components/jump-badge/jump-badge.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AAOzD,MAAM,OAAO,
|
|
1
|
+
{"version":3,"file":"jump-badge.js","sourceRoot":"","sources":["../../../src/components/jump-badge/jump-badge.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AAOzD,MAAM,OAAO,QAAQ;;qBAIK,EAAE;uBAKe,SAAS;;IAElD,MAAM;QACJ,OAAO,CACL,EAAC,IAAI,qDAAC,OAAO,EAAE,IAAI,CAAC,OAAO,IACxB,IAAI,CAAC,KAAK,CACN,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAEF","sourcesContent":["import { Component, Host, h, Prop } from '@stencil/core';\n\n@Component({\n tag: 'jump-badge',\n styleUrl: 'jump-badge.scss',\n shadow: false,\n})\nexport class AppBadge {\n /**\n * Indicates the label of the badge\n */\n @Prop() label: string = '';\n\n /**\n * Indicates the variant of the badge\n */\n @Prop() variant: 'primary'|'secondary' = 'primary';\n\n render() {\n return (\n <Host variant={this.variant}>\n {this.label}\n </Host>\n );\n }\n\n}\n"]}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { newSpecPage } from "@stencil/core/testing";
|
|
2
|
-
import {
|
|
2
|
+
import { AppBadge } from "../jump-badge";
|
|
3
3
|
describe('jump-badge', () => {
|
|
4
4
|
it('renders', async () => {
|
|
5
5
|
const page = await newSpecPage({
|
|
6
|
-
components: [
|
|
6
|
+
components: [AppBadge],
|
|
7
7
|
html: `<jump-badge></jump-badge>`,
|
|
8
8
|
});
|
|
9
9
|
expect(page.root).toEqualHtml(`
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"jump-badge.spec.js","sourceRoot":"","sources":["../../../../src/components/jump-badge/test/jump-badge.spec.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACpD,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"jump-badge.spec.js","sourceRoot":"","sources":["../../../../src/components/jump-badge/test/jump-badge.spec.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACpD,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AAEzC,QAAQ,CAAC,YAAY,EAAE,GAAG,EAAE;IAC1B,EAAE,CAAC,SAAS,EAAE,KAAK,IAAI,EAAE;QACvB,MAAM,IAAI,GAAG,MAAM,WAAW,CAAC;YAC7B,UAAU,EAAE,CAAC,QAAQ,CAAC;YACtB,IAAI,EAAE,2BAA2B;SAClC,CAAC,CAAC;QACH,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,WAAW,CAAC;;;;;;KAM7B,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC","sourcesContent":["import { newSpecPage } from '@stencil/core/testing';\nimport { AppBadge } from '../jump-badge';\n\ndescribe('jump-badge', () => {\n it('renders', async () => {\n const page = await newSpecPage({\n components: [AppBadge],\n html: `<jump-badge></jump-badge>`,\n });\n expect(page.root).toEqualHtml(`\n <jump-badge>\n <mock:shadow-root>\n <slot></slot>\n </mock:shadow-root>\n </jump-badge>\n `);\n });\n});\n"]}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import { generateAttributesFromArgs } from "../../utils/utils";
|
|
2
|
+
export default {
|
|
3
|
+
title: 'Components/Button/Anchor',
|
|
4
|
+
tags: ['autodocs'],
|
|
5
|
+
argTypes: {
|
|
6
|
+
variant: {
|
|
7
|
+
name: 'Variante',
|
|
8
|
+
description: 'Imposta la variante di colore del link',
|
|
9
|
+
control: 'select',
|
|
10
|
+
options: [
|
|
11
|
+
'primary',
|
|
12
|
+
'secondary',
|
|
13
|
+
'neutral',
|
|
14
|
+
'white'
|
|
15
|
+
],
|
|
16
|
+
},
|
|
17
|
+
size: {
|
|
18
|
+
name: 'Dimensione',
|
|
19
|
+
description: 'Imposta la dimensione del link',
|
|
20
|
+
control: 'select',
|
|
21
|
+
options: [
|
|
22
|
+
'small',
|
|
23
|
+
'medium',
|
|
24
|
+
'large'
|
|
25
|
+
],
|
|
26
|
+
labels: {
|
|
27
|
+
small: 'Piccolo',
|
|
28
|
+
medium: 'Medio',
|
|
29
|
+
large: 'Grande'
|
|
30
|
+
}
|
|
31
|
+
},
|
|
32
|
+
disabled: {
|
|
33
|
+
name: 'Disabilitato',
|
|
34
|
+
description: 'Imposta se il link deve essere disabilitato',
|
|
35
|
+
control: 'boolean'
|
|
36
|
+
},
|
|
37
|
+
text: {
|
|
38
|
+
name: 'Testo',
|
|
39
|
+
description: 'Imposta se il link è solo testo, quindi senza bordo, sfondo e padding',
|
|
40
|
+
control: 'boolean'
|
|
41
|
+
},
|
|
42
|
+
id: {
|
|
43
|
+
name: 'ID',
|
|
44
|
+
description: 'Imposta l\'id del link',
|
|
45
|
+
control: 'text'
|
|
46
|
+
},
|
|
47
|
+
}
|
|
48
|
+
};
|
|
49
|
+
const Template = (args) => {
|
|
50
|
+
const attributes = generateAttributesFromArgs(args);
|
|
51
|
+
return `<jump-button ${attributes} href="www.jumpgroup.it" target="_blank"> Scopri di più </jump-button>`;
|
|
52
|
+
};
|
|
53
|
+
const TemplateWithIcon = (args) => {
|
|
54
|
+
const attributes = generateAttributesFromArgs(args);
|
|
55
|
+
return `<jump-button ${attributes} href="www.jumpgroup.it" target="_blank"> <jump-icon slot="suffix" name="arrow-right"></jump-icon> Scopri di più </jump-button>`;
|
|
56
|
+
};
|
|
57
|
+
export const LinkPrimary = Template.bind({});
|
|
58
|
+
LinkPrimary.args = {
|
|
59
|
+
variant: 'primary',
|
|
60
|
+
size: 'small',
|
|
61
|
+
text: true,
|
|
62
|
+
};
|
|
63
|
+
export const LinkSecondary = Template.bind({});
|
|
64
|
+
LinkSecondary.args = {
|
|
65
|
+
variant: 'secondary',
|
|
66
|
+
size: 'medium',
|
|
67
|
+
text: true,
|
|
68
|
+
};
|
|
69
|
+
export const LinkNeutral = Template.bind({});
|
|
70
|
+
LinkNeutral.args = {
|
|
71
|
+
variant: 'neutral',
|
|
72
|
+
size: 'large',
|
|
73
|
+
text: true,
|
|
74
|
+
};
|
|
75
|
+
export const LinkWhite = Template.bind({});
|
|
76
|
+
LinkWhite.args = {
|
|
77
|
+
variant: 'white',
|
|
78
|
+
size: 'medium',
|
|
79
|
+
text: true,
|
|
80
|
+
};
|
|
81
|
+
export const LinkWithIcon = TemplateWithIcon.bind({});
|
|
82
|
+
LinkWithIcon.args = {
|
|
83
|
+
variant: 'primary',
|
|
84
|
+
size: 'medium',
|
|
85
|
+
text: true,
|
|
86
|
+
};
|
|
87
|
+
//# sourceMappingURL=jump-button-anchor.stories.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"jump-button-anchor.stories.js","sourceRoot":"","sources":["../../../src/components/jump-button/jump-button-anchor.stories.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,0BAA0B,EAAC,MAAM,mBAAmB,CAAC;AAE9D,eAAe;IACb,KAAK,EAAE,0BAA0B;IACjC,IAAI,EAAE,CAAC,UAAU,CAAC;IAClB,QAAQ,EAAE;QACR,OAAO,EAAE;YACP,IAAI,EAAE,UAAU;YAChB,WAAW,EAAE,wCAAwC;YACrD,OAAO,EAAE,QAAQ;YACjB,OAAO,EAAE;gBACP,SAAS;gBACT,WAAW;gBACX,SAAS;gBACT,OAAO;aACR;SACF;QACD,IAAI,EAAE;YACJ,IAAI,EAAE,YAAY;YAClB,WAAW,EAAE,gCAAgC;YAC7C,OAAO,EAAE,QAAQ;YACjB,OAAO,EAAE;gBACP,OAAO;gBACP,QAAQ;gBACR,OAAO;aACR;YACD,MAAM,EAAE;gBACN,KAAK,EAAE,SAAS;gBAChB,MAAM,EAAE,OAAO;gBACf,KAAK,EAAE,QAAQ;aAChB;SACF;QACD,QAAQ,EAAE;YACR,IAAI,EAAE,cAAc;YACpB,WAAW,EAAE,6CAA6C;YAC1D,OAAO,EAAE,SAAS;SACnB;QACD,IAAI,EAAE;YACJ,IAAI,EAAE,OAAO;Y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IACd,IAAI,EAAE,IAAI;CACX,CAAC;AAEF,MAAM,CAAC,MAAM,YAAY,GAAG,gBAAgB,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AACtD,YAAY,CAAC,IAAI,GAAG;IAClB,OAAO,EAAE,SAAS;IAClB,IAAI,EAAE,QAAQ;IACd,IAAI,EAAE,IAAI;CACX,CAAC","sourcesContent":["import { generateAttributesFromArgs} from '../../utils/utils';\n\nexport default {\n title: 'Components/Button/Anchor',\n tags: ['autodocs'],\n argTypes: {\n variant: {\n name: 'Variante',\n description: 'Imposta la variante di colore del link',\n control: 'select',\n options: [\n 'primary',\n 'secondary',\n 'neutral',\n 'white'\n ],\n },\n size: {\n name: 'Dimensione',\n description: 'Imposta la dimensione del link',\n control: 'select',\n options: [\n 'small',\n 'medium',\n 'large'\n ],\n labels: {\n small: 'Piccolo',\n medium: 'Medio',\n large: 'Grande'\n }\n },\n disabled: {\n name: 'Disabilitato',\n description: 'Imposta se il link deve essere disabilitato',\n control: 'boolean'\n },\n text: {\n name: 'Testo',\n description: 'Imposta se il link è solo testo, quindi senza bordo, sfondo e padding',\n control: 'boolean'\n },\n id: {\n name: 'ID',\n description: 'Imposta l\\'id del link',\n control: 'text'\n },\n }\n};\n\nconst Template = (args) => {\n const attributes = generateAttributesFromArgs(args);\n return `<jump-button ${attributes} href=\"www.jumpgroup.it\" target=\"_blank\"> Scopri di più </jump-button>`\n}\n\nconst TemplateWithIcon = (args) => {\n const attributes = generateAttributesFromArgs(args);\n return `<jump-button ${attributes} href=\"www.jumpgroup.it\" target=\"_blank\"> <jump-icon slot=\"suffix\" name=\"arrow-right\"></jump-icon> Scopri di più </jump-button>`\n}\n\nexport const LinkPrimary = Template.bind({});\nLinkPrimary.args = {\n variant: 'primary',\n size: 'small',\n text: true,\n};\n\nexport const LinkSecondary = Template.bind({});\nLinkSecondary.args = {\n variant: 'secondary',\n size: 'medium',\n text: true,\n};\n\nexport const LinkNeutral = Template.bind({});\nLinkNeutral.args = {\n variant: 'neutral',\n size: 'large',\n text: true,\n};\n\nexport const LinkWhite = Template.bind({});\nLinkWhite.args = {\n variant: 'white',\n size: 'medium',\n text: true,\n};\n\nexport const LinkWithIcon = TemplateWithIcon.bind({});\nLinkWithIcon.args = {\n variant: 'primary',\n size: 'medium',\n text: true,\n};"]}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import { generateAttributesFromArgs } from "../../utils/utils";
|
|
2
|
+
export default {
|
|
3
|
+
title: 'Components/Button/Dimension',
|
|
4
|
+
tags: ['autodocs'],
|
|
5
|
+
argTypes: {
|
|
6
|
+
variant: {
|
|
7
|
+
name: 'Variante',
|
|
8
|
+
description: 'Imposta la variante di colore del bottone',
|
|
9
|
+
control: 'select',
|
|
10
|
+
options: [
|
|
11
|
+
'primary',
|
|
12
|
+
'secondary',
|
|
13
|
+
'neutral',
|
|
14
|
+
'white'
|
|
15
|
+
],
|
|
16
|
+
},
|
|
17
|
+
size: {
|
|
18
|
+
name: 'Dimensione',
|
|
19
|
+
description: 'Imposta la dimensione del bottone',
|
|
20
|
+
control: 'select',
|
|
21
|
+
options: [
|
|
22
|
+
'small',
|
|
23
|
+
'medium',
|
|
24
|
+
'large'
|
|
25
|
+
],
|
|
26
|
+
labels: {
|
|
27
|
+
small: 'Piccolo',
|
|
28
|
+
medium: 'Medio',
|
|
29
|
+
large: 'Grande'
|
|
30
|
+
}
|
|
31
|
+
},
|
|
32
|
+
full: {
|
|
33
|
+
name: 'Full Width',
|
|
34
|
+
description: 'Imposta se il bottone sarà largo tutto lo spazio che può occupare',
|
|
35
|
+
control: 'boolean'
|
|
36
|
+
},
|
|
37
|
+
text: {
|
|
38
|
+
name: 'Testo',
|
|
39
|
+
description: 'Imposta se il bottone è solo testo, quindi senza bordo, sfondo e padding',
|
|
40
|
+
control: 'boolean'
|
|
41
|
+
},
|
|
42
|
+
id: {
|
|
43
|
+
name: 'ID',
|
|
44
|
+
description: 'Imposta l\'id del bottone',
|
|
45
|
+
control: 'text'
|
|
46
|
+
},
|
|
47
|
+
}
|
|
48
|
+
};
|
|
49
|
+
const Template = (args) => {
|
|
50
|
+
const attributes = generateAttributesFromArgs(args);
|
|
51
|
+
return `<jump-button ${attributes} outline name="scopri" value="value" aria-label="Scopri di più"> <jump-icon slot="suffix" name="arrow-right"></jump-icon> Scopri di più </jump-button>`;
|
|
52
|
+
};
|
|
53
|
+
export const Small = Template.bind({});
|
|
54
|
+
Small.args = {
|
|
55
|
+
variant: 'primary',
|
|
56
|
+
size: 'small',
|
|
57
|
+
};
|
|
58
|
+
export const Medium = Template.bind({});
|
|
59
|
+
Medium.args = {
|
|
60
|
+
variant: 'primary',
|
|
61
|
+
size: 'medium',
|
|
62
|
+
};
|
|
63
|
+
export const Large = Template.bind({});
|
|
64
|
+
Large.args = {
|
|
65
|
+
variant: 'primary',
|
|
66
|
+
size: 'large',
|
|
67
|
+
};
|
|
68
|
+
export const Full = Template.bind({});
|
|
69
|
+
Full.args = {
|
|
70
|
+
variant: 'primary',
|
|
71
|
+
size: 'medium',
|
|
72
|
+
full: true,
|
|
73
|
+
};
|
|
74
|
+
//# sourceMappingURL=jump-button-dimension.stories.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"jump-button-dimension.stories.js","sourceRoot":"","sources":["../../../src/components/jump-button/jump-button-dimension.stories.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,0BAA0B,EAAC,MAAM,mBAAmB,CAAC;AAE9D,eAAe;IACb,KAAK,EAAE,6BAA6B;IACpC,IAAI,EAAE,CAAC,UAAU,CAAC;IAClB,QAAQ,EAAE;QACR,OAAO,EAAE;YACP,IAAI,EAAE,UAAU;YAChB,WAAW,EAAE,2CAA2C;YACxD,OAAO,EAAE,QAAQ;YACjB,OAAO,EAAE;gBACP,SAAS;gBACT,WAAW;gBACX,SAAS;gBACT,OAAO;aACR;SACF;QACD,IAAI,EAAE;YACJ,IAAI,EAAE,YAAY;YAClB,WAAW,EAAE,mCAAmC;YAChD,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AC;AACtC,IAAI,CAAC,IAAI,GAAG;IACV,OAAO,EAAE,SAAS;IAClB,IAAI,EAAE,QAAQ;IACd,IAAI,EAAE,IAAI;CACX,CAAC","sourcesContent":["import { generateAttributesFromArgs} from '../../utils/utils';\n\nexport default {\n title: 'Components/Button/Dimension',\n tags: ['autodocs'],\n argTypes: {\n variant: {\n name: 'Variante',\n description: 'Imposta la variante di colore del bottone',\n control: 'select',\n options: [\n 'primary',\n 'secondary',\n 'neutral',\n 'white'\n ],\n },\n size: {\n name: 'Dimensione',\n description: 'Imposta la dimensione del bottone',\n control: 'select',\n options: [\n 'small',\n 'medium',\n 'large'\n ],\n labels: {\n small: 'Piccolo',\n medium: 'Medio',\n large: 'Grande'\n }\n },\n full: {\n name: 'Full Width',\n description: 'Imposta se il bottone sarà largo tutto lo spazio che può occupare',\n control: 'boolean'\n },\n text: {\n name: 'Testo',\n description: 'Imposta se il bottone è solo testo, quindi senza bordo, sfondo e padding',\n control: 'boolean'\n },\n id: {\n name: 'ID',\n description: 'Imposta l\\'id del bottone',\n control: 'text'\n },\n }\n};\n\nconst Template = (args) => {\n const attributes = generateAttributesFromArgs(args);\n return `<jump-button ${attributes} outline name=\"scopri\" value=\"value\" aria-label=\"Scopri di più\"> <jump-icon slot=\"suffix\" name=\"arrow-right\"></jump-icon> Scopri di più </jump-button>`\n}\n\nexport const Small = Template.bind({});\nSmall.args = {\n variant: 'primary',\n size: 'small',\n};\n\nexport const Medium = Template.bind({});\nMedium.args = {\n variant: 'primary',\n size: 'medium',\n};\n\nexport const Large = Template.bind({});\nLarge.args = {\n variant: 'primary',\n size: 'large',\n};\n\nexport const Full = Template.bind({});\nFull.args = {\n variant: 'primary',\n size: 'medium',\n full: true,\n};\n"]}
|