@amiceli/papierjs 0.0.1
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/LICENSE +21 -0
- package/README.md +52 -0
- package/dist/cjs/app-globals-3a1e7e63.js +7 -0
- package/dist/cjs/app-globals-3a1e7e63.js.map +1 -0
- package/dist/cjs/index-028aee0a.js +1292 -0
- package/dist/cjs/index-028aee0a.js.map +1 -0
- package/dist/cjs/index.cjs.js +4 -0
- package/dist/cjs/index.cjs.js.map +1 -0
- package/dist/cjs/loader.cjs.js +17 -0
- package/dist/cjs/loader.cjs.js.map +1 -0
- package/dist/cjs/p-alert.cjs.entry.js +52 -0
- package/dist/cjs/p-alert.cjs.entry.js.map +1 -0
- package/dist/cjs/p-button.cjs.entry.js +57 -0
- package/dist/cjs/p-button.cjs.entry.js.map +1 -0
- package/dist/cjs/p-progress-bar.cjs.entry.js +54 -0
- package/dist/cjs/p-progress-bar.cjs.entry.js.map +1 -0
- package/dist/cjs/papierjs.cjs.js +27 -0
- package/dist/cjs/papierjs.cjs.js.map +1 -0
- package/dist/collection/collection-manifest.json +14 -0
- package/dist/collection/components/alert/alert.css +3448 -0
- package/dist/collection/components/alert/alert.js +138 -0
- package/dist/collection/components/alert/alert.js.map +1 -0
- package/dist/collection/components/button/button.css +3438 -0
- package/dist/collection/components/button/button.js +206 -0
- package/dist/collection/components/button/button.js.map +1 -0
- package/dist/collection/components/progress-bar/progress-bar.css +3438 -0
- package/dist/collection/components/progress-bar/progress-bar.js +143 -0
- package/dist/collection/components/progress-bar/progress-bar.js.map +1 -0
- package/dist/collection/index.js +2 -0
- package/dist/collection/index.js.map +1 -0
- package/dist/components/index.d.ts +33 -0
- package/dist/components/index.js +3 -0
- package/dist/components/index.js.map +1 -0
- package/dist/components/p-5ec03f76.js +1074 -0
- package/dist/components/p-5ec03f76.js.map +1 -0
- package/dist/components/p-alert.d.ts +11 -0
- package/dist/components/p-alert.js +71 -0
- package/dist/components/p-alert.js.map +1 -0
- package/dist/components/p-button.d.ts +11 -0
- package/dist/components/p-button.js +80 -0
- package/dist/components/p-button.js.map +1 -0
- package/dist/components/p-progress-bar.d.ts +11 -0
- package/dist/components/p-progress-bar.js +74 -0
- package/dist/components/p-progress-bar.js.map +1 -0
- package/dist/esm/app-globals-0f993ce5.js +5 -0
- package/dist/esm/app-globals-0f993ce5.js.map +1 -0
- package/dist/esm/index-ad124052.js +1265 -0
- package/dist/esm/index-ad124052.js.map +1 -0
- package/dist/esm/index.js +3 -0
- package/dist/esm/index.js.map +1 -0
- package/dist/esm/loader.js +13 -0
- package/dist/esm/loader.js.map +1 -0
- package/dist/esm/p-alert.entry.js +48 -0
- package/dist/esm/p-alert.entry.js.map +1 -0
- package/dist/esm/p-button.entry.js +53 -0
- package/dist/esm/p-button.entry.js.map +1 -0
- package/dist/esm/p-progress-bar.entry.js +50 -0
- package/dist/esm/p-progress-bar.entry.js.map +1 -0
- package/dist/esm/papierjs.js +22 -0
- package/dist/esm/papierjs.js.map +1 -0
- package/dist/index.cjs.js +1 -0
- package/dist/index.js +1 -0
- package/dist/papierjs/index.esm.js +2 -0
- package/dist/papierjs/index.esm.js.map +1 -0
- package/dist/papierjs/p-14f67b19.entry.js +2 -0
- package/dist/papierjs/p-14f67b19.entry.js.map +1 -0
- package/dist/papierjs/p-8ae1632f.entry.js +2 -0
- package/dist/papierjs/p-8ae1632f.entry.js.map +1 -0
- package/dist/papierjs/p-be2fe2c0.js +3 -0
- package/dist/papierjs/p-be2fe2c0.js.map +1 -0
- package/dist/papierjs/p-d1c3c0ac.entry.js +2 -0
- package/dist/papierjs/p-d1c3c0ac.entry.js.map +1 -0
- package/dist/papierjs/p-e1255160.js +2 -0
- package/dist/papierjs/p-e1255160.js.map +1 -0
- package/dist/papierjs/papierjs.esm.js +2 -0
- package/dist/papierjs/papierjs.esm.js.map +1 -0
- package/dist/types/components/alert/alert.d.ts +13 -0
- package/dist/types/components/button/button.d.ts +14 -0
- package/dist/types/components/progress-bar/progress-bar.d.ts +11 -0
- package/dist/types/components.d.ts +107 -0
- package/dist/types/index.d.ts +10 -0
- package/dist/types/stencil-public-runtime.d.ts +1680 -0
- package/loader/cdn.js +1 -0
- package/loader/index.cjs.js +1 -0
- package/loader/index.d.ts +24 -0
- package/loader/index.es2017.js +1 -0
- package/loader/index.js +2 -0
- package/loader/package.json +11 -0
- package/package.json +80 -0
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
// biome-ignore lint/correctness/noUnusedImports: required for jsx
|
|
2
|
+
import { h } from "@stencil/core";
|
|
3
|
+
export class ProgressBar {
|
|
4
|
+
constructor() {
|
|
5
|
+
this.type = 'primary';
|
|
6
|
+
this.value = 0;
|
|
7
|
+
this.striped = false;
|
|
8
|
+
this.dark = false;
|
|
9
|
+
}
|
|
10
|
+
getClass() {
|
|
11
|
+
const types = [
|
|
12
|
+
'secondary',
|
|
13
|
+
'success',
|
|
14
|
+
'warning',
|
|
15
|
+
'danger',
|
|
16
|
+
'muted',
|
|
17
|
+
'primary',
|
|
18
|
+
];
|
|
19
|
+
let cssClass = `bar w-${this.value}`;
|
|
20
|
+
if (!types.includes(this.type)) {
|
|
21
|
+
cssClass = `${cssClass} primary`;
|
|
22
|
+
}
|
|
23
|
+
else {
|
|
24
|
+
cssClass = `${cssClass} ${this.type}`;
|
|
25
|
+
}
|
|
26
|
+
if (this.striped) {
|
|
27
|
+
cssClass = `${cssClass} striped`;
|
|
28
|
+
}
|
|
29
|
+
return cssClass;
|
|
30
|
+
}
|
|
31
|
+
getParentClass() {
|
|
32
|
+
let cssClass = 'papier is--block';
|
|
33
|
+
if (this.dark) {
|
|
34
|
+
cssClass = `${cssClass} is--dark`;
|
|
35
|
+
}
|
|
36
|
+
return cssClass;
|
|
37
|
+
}
|
|
38
|
+
render() {
|
|
39
|
+
return (h("div", { key: '00775762381af67d2731ea4480fa0a0c4cbbf8b4', class: this.getParentClass() }, h("div", { key: '424fcbf00f05a00791fa8f0229dc98f393bd41e7', class: "progress" }, h("div", { key: '8b5c91514194ca154f04ae9b350c7c93cfbcd629', class: this.getClass() }, h("slot", { key: 'ce392a0c50b52033a03aba975a8373a7e8f1fa12' })))));
|
|
40
|
+
}
|
|
41
|
+
static get is() { return "p-progress-bar"; }
|
|
42
|
+
static get encapsulation() { return "shadow"; }
|
|
43
|
+
static get originalStyleUrls() {
|
|
44
|
+
return {
|
|
45
|
+
"$": ["progress-bar.scss"]
|
|
46
|
+
};
|
|
47
|
+
}
|
|
48
|
+
static get styleUrls() {
|
|
49
|
+
return {
|
|
50
|
+
"$": ["progress-bar.css"]
|
|
51
|
+
};
|
|
52
|
+
}
|
|
53
|
+
static get properties() {
|
|
54
|
+
return {
|
|
55
|
+
"type": {
|
|
56
|
+
"type": "string",
|
|
57
|
+
"mutable": false,
|
|
58
|
+
"complexType": {
|
|
59
|
+
"original": "ProgressBarColor",
|
|
60
|
+
"resolved": "\"danger\" | \"muted\" | \"primary\" | \"secondary\" | \"success\" | \"warning\"",
|
|
61
|
+
"references": {
|
|
62
|
+
"ProgressBarColor": {
|
|
63
|
+
"location": "global",
|
|
64
|
+
"id": "global::ProgressBarColor"
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
},
|
|
68
|
+
"required": false,
|
|
69
|
+
"optional": true,
|
|
70
|
+
"docs": {
|
|
71
|
+
"tags": [],
|
|
72
|
+
"text": ""
|
|
73
|
+
},
|
|
74
|
+
"getter": false,
|
|
75
|
+
"setter": false,
|
|
76
|
+
"attribute": "type",
|
|
77
|
+
"reflect": false,
|
|
78
|
+
"defaultValue": "'primary'"
|
|
79
|
+
},
|
|
80
|
+
"value": {
|
|
81
|
+
"type": "number",
|
|
82
|
+
"mutable": false,
|
|
83
|
+
"complexType": {
|
|
84
|
+
"original": "number",
|
|
85
|
+
"resolved": "number",
|
|
86
|
+
"references": {}
|
|
87
|
+
},
|
|
88
|
+
"required": false,
|
|
89
|
+
"optional": true,
|
|
90
|
+
"docs": {
|
|
91
|
+
"tags": [],
|
|
92
|
+
"text": ""
|
|
93
|
+
},
|
|
94
|
+
"getter": false,
|
|
95
|
+
"setter": false,
|
|
96
|
+
"attribute": "value",
|
|
97
|
+
"reflect": false,
|
|
98
|
+
"defaultValue": "0"
|
|
99
|
+
},
|
|
100
|
+
"striped": {
|
|
101
|
+
"type": "boolean",
|
|
102
|
+
"mutable": false,
|
|
103
|
+
"complexType": {
|
|
104
|
+
"original": "boolean",
|
|
105
|
+
"resolved": "boolean",
|
|
106
|
+
"references": {}
|
|
107
|
+
},
|
|
108
|
+
"required": false,
|
|
109
|
+
"optional": true,
|
|
110
|
+
"docs": {
|
|
111
|
+
"tags": [],
|
|
112
|
+
"text": ""
|
|
113
|
+
},
|
|
114
|
+
"getter": false,
|
|
115
|
+
"setter": false,
|
|
116
|
+
"attribute": "striped",
|
|
117
|
+
"reflect": false,
|
|
118
|
+
"defaultValue": "false"
|
|
119
|
+
},
|
|
120
|
+
"dark": {
|
|
121
|
+
"type": "boolean",
|
|
122
|
+
"mutable": false,
|
|
123
|
+
"complexType": {
|
|
124
|
+
"original": "boolean",
|
|
125
|
+
"resolved": "boolean",
|
|
126
|
+
"references": {}
|
|
127
|
+
},
|
|
128
|
+
"required": false,
|
|
129
|
+
"optional": true,
|
|
130
|
+
"docs": {
|
|
131
|
+
"tags": [],
|
|
132
|
+
"text": ""
|
|
133
|
+
},
|
|
134
|
+
"getter": false,
|
|
135
|
+
"setter": false,
|
|
136
|
+
"attribute": "dark",
|
|
137
|
+
"reflect": false,
|
|
138
|
+
"defaultValue": "false"
|
|
139
|
+
}
|
|
140
|
+
};
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
//# sourceMappingURL=progress-bar.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"progress-bar.js","sourceRoot":"","sources":["../../../src/components/progress-bar/progress-bar.tsx"],"names":[],"mappings":"AAAA,kEAAkE;AAClE,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,M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","sourcesContent":["// biome-ignore lint/correctness/noUnusedImports: required for jsx\nimport { Component, Prop, h } from '@stencil/core'\n\ntype ProgressBarColor =\n | 'secondary'\n | 'success'\n | 'warning'\n | 'danger'\n | 'muted'\n | 'primary'\n\n@Component({\n tag: 'p-progress-bar',\n styleUrl: 'progress-bar.scss',\n shadow: true,\n})\nexport class ProgressBar {\n @Prop()\n type?: ProgressBarColor = 'primary'\n @Prop()\n value?: number = 0\n @Prop()\n striped?: boolean = false\n @Prop()\n dark?: boolean = false\n\n public getClass(): string {\n const types = [\n 'secondary',\n 'success',\n 'warning',\n 'danger',\n 'muted',\n 'primary',\n ]\n let cssClass = `bar w-${this.value}`\n\n if (!types.includes(this.type)) {\n cssClass = `${cssClass} primary`\n } else {\n cssClass = `${cssClass} ${this.type}`\n }\n\n if (this.striped) {\n cssClass = `${cssClass} striped`\n }\n\n return cssClass\n }\n\n public getParentClass() {\n let cssClass = 'papier is--block'\n\n if (this.dark) {\n cssClass = `${cssClass} is--dark`\n }\n\n return cssClass\n }\n\n render() {\n return (\n <div class={this.getParentClass()}>\n <div class=\"progress\">\n <div class={this.getClass()}>\n <slot />\n </div>\n </div>\n </div>\n )\n }\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG","sourcesContent":["/**\n * @fileoverview entry point for your component library\n *\n * This is the entry point for your component library. Use this file to export utilities,\n * constants or data structure that accompany your components.\n *\n * DO NOT use this file to export your components. Instead, use the recommended approaches\n * to consume components of this package as outlined in the `README.md`.\n */\n\nexport type * from './components.d.ts'\n"]}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Get the base path to where the assets can be found. Use "setAssetPath(path)"
|
|
3
|
+
* if the path needs to be customized.
|
|
4
|
+
*/
|
|
5
|
+
export declare const getAssetPath: (path: string) => string;
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* Used to manually set the base path where assets can be found.
|
|
9
|
+
* If the script is used as "module", it's recommended to use "import.meta.url",
|
|
10
|
+
* such as "setAssetPath(import.meta.url)". Other options include
|
|
11
|
+
* "setAssetPath(document.currentScript.src)", or using a bundler's replace plugin to
|
|
12
|
+
* dynamically set the path at build time, such as "setAssetPath(process.env.ASSET_PATH)".
|
|
13
|
+
* But do note that this configuration depends on how your script is bundled, or lack of
|
|
14
|
+
* bundling, and where your assets can be loaded from. Additionally custom bundling
|
|
15
|
+
* will have to ensure the static assets are copied to its build directory.
|
|
16
|
+
*/
|
|
17
|
+
export declare const setAssetPath: (path: string) => void;
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* Used to specify a nonce value that corresponds with an application's CSP.
|
|
21
|
+
* When set, the nonce will be added to all dynamically created script and style tags at runtime.
|
|
22
|
+
* Alternatively, the nonce value can be set on a meta tag in the DOM head
|
|
23
|
+
* (<meta name="csp-nonce" content="{ nonce value here }" />) which
|
|
24
|
+
* will result in the same behavior.
|
|
25
|
+
*/
|
|
26
|
+
export declare const setNonce: (nonce: string) => void
|
|
27
|
+
|
|
28
|
+
export interface SetPlatformOptions {
|
|
29
|
+
raf?: (c: FrameRequestCallback) => number;
|
|
30
|
+
ael?: (el: EventTarget, eventName: string, listener: EventListenerOrEventListenerObject, options: boolean | AddEventListenerOptions) => void;
|
|
31
|
+
rel?: (el: EventTarget, eventName: string, listener: EventListenerOrEventListenerObject, options: boolean | AddEventListenerOptions) => void;
|
|
32
|
+
}
|
|
33
|
+
export declare const setPlatformOptions: (opts: SetPlatformOptions) => void;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"file":"index.js","mappings":"","names":[],"sources":[],"sourcesContent":[],"version":3}
|