@maggioli-design-system/mds-accordion-timer 4.0.0 → 4.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/dist/cjs/mds-accordion-timer.cjs.entry.js +16 -12
- package/dist/collection/common/aria.js +17 -1
- package/dist/collection/common/device.js +6 -0
- package/dist/collection/common/keyboard-manager.js +2 -2
- package/dist/collection/components/mds-accordion-timer/mds-accordion-timer.js +16 -12
- package/dist/collection/dictionary/file-extensions.js +114 -56
- package/dist/collection/dictionary/text.js +60 -1
- package/dist/components/mds-accordion-timer.js +16 -12
- package/dist/documentation.json +1 -1
- package/dist/esm/mds-accordion-timer.entry.js +16 -12
- package/dist/esm-es5/mds-accordion-timer.entry.js +1 -1
- package/dist/mds-accordion-timer/mds-accordion-timer.esm.js +1 -1
- package/dist/mds-accordion-timer/p-25856ee2.system.js +1 -1
- package/dist/mds-accordion-timer/p-4eb3ec08.system.entry.js +1 -0
- package/dist/mds-accordion-timer/p-86e0d6b4.entry.js +1 -0
- package/dist/stats.json +18 -16
- package/dist/types/common/aria.d.ts +3 -1
- package/dist/types/common/device.d.ts +2 -0
- package/dist/types/dictionary/text.d.ts +3 -1
- package/dist/types/type/text.d.ts +2 -0
- package/documentation.json +9 -4
- package/package.json +2 -2
- package/src/common/aria.ts +22 -2
- package/src/common/device.ts +9 -0
- package/src/common/keyboard-manager.ts +2 -2
- package/src/components/mds-accordion-timer/mds-accordion-timer.tsx +15 -11
- package/src/dictionary/file-extensions.ts +115 -56
- package/src/dictionary/text.ts +64 -0
- package/src/fixtures/icons.json +8 -0
- package/src/fixtures/iconsauce.json +5 -0
- package/src/meta/file-format/locale.el.json +39 -0
- package/src/meta/file-format/locale.en.json +39 -0
- package/src/meta/file-format/locale.es.json +39 -0
- package/src/meta/file-format/locale.it.json +39 -0
- package/src/type/text.ts +59 -0
- package/www/build/mds-accordion-timer.esm.js +1 -1
- package/www/build/p-25856ee2.system.js +1 -1
- package/www/build/p-4eb3ec08.system.entry.js +1 -0
- package/www/build/p-86e0d6b4.entry.js +1 -0
- package/dist/mds-accordion-timer/p-4dac14fb.entry.js +0 -1
- package/dist/mds-accordion-timer/p-7ae27bb3.system.entry.js +0 -1
- package/www/build/p-4dac14fb.entry.js +0 -1
- package/www/build/p-7ae27bb3.system.entry.js +0 -1
package/dist/stats.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"timestamp": "2024-
|
|
2
|
+
"timestamp": "2024-12-04T18:05:07",
|
|
3
3
|
"compiler": {
|
|
4
4
|
"name": "node",
|
|
5
5
|
"version": "22.11.0"
|
|
@@ -9,14 +9,15 @@
|
|
|
9
9
|
"fsNamespace": "mds-accordion-timer",
|
|
10
10
|
"components": 1,
|
|
11
11
|
"entries": 1,
|
|
12
|
-
"bundles":
|
|
12
|
+
"bundles": 93,
|
|
13
13
|
"outputs": [
|
|
14
14
|
{
|
|
15
15
|
"name": "dist-collection",
|
|
16
|
-
"files":
|
|
16
|
+
"files": 45,
|
|
17
17
|
"generatedFiles": [
|
|
18
18
|
"./dist/collection/common/aria.js",
|
|
19
19
|
"./dist/collection/common/date.js",
|
|
20
|
+
"./dist/collection/common/device.js",
|
|
20
21
|
"./dist/collection/common/file.js",
|
|
21
22
|
"./dist/collection/common/icon.js",
|
|
22
23
|
"./dist/collection/common/keyboard-manager.js",
|
|
@@ -99,22 +100,22 @@
|
|
|
99
100
|
"./dist/mds-accordion-timer/mds-accordion-timer.esm.js",
|
|
100
101
|
"./dist/mds-accordion-timer/mds-accordion-timer.js",
|
|
101
102
|
"./dist/mds-accordion-timer/p-25856ee2.system.js",
|
|
102
|
-
"./dist/mds-accordion-timer/p-
|
|
103
|
+
"./dist/mds-accordion-timer/p-4eb3ec08.system.entry.js",
|
|
103
104
|
"./dist/mds-accordion-timer/p-50ea2036.system.js",
|
|
104
105
|
"./dist/mds-accordion-timer/p-56ba5cbf.system.js",
|
|
105
106
|
"./dist/mds-accordion-timer/p-62c48ff3.system.js",
|
|
106
|
-
"./dist/mds-accordion-timer/p-
|
|
107
|
+
"./dist/mds-accordion-timer/p-86e0d6b4.entry.js",
|
|
107
108
|
"./dist/mds-accordion-timer/p-8dd37a13.js",
|
|
108
109
|
"./dist/mds-accordion-timer/p-e1255160.js",
|
|
109
110
|
"./www/build/index.esm.js",
|
|
110
111
|
"./www/build/mds-accordion-timer.esm.js",
|
|
111
112
|
"./www/build/mds-accordion-timer.js",
|
|
112
113
|
"./www/build/p-25856ee2.system.js",
|
|
113
|
-
"./www/build/p-
|
|
114
|
+
"./www/build/p-4eb3ec08.system.entry.js",
|
|
114
115
|
"./www/build/p-50ea2036.system.js",
|
|
115
116
|
"./www/build/p-56ba5cbf.system.js",
|
|
116
117
|
"./www/build/p-62c48ff3.system.js",
|
|
117
|
-
"./www/build/p-
|
|
118
|
+
"./www/build/p-86e0d6b4.entry.js",
|
|
118
119
|
"./www/build/p-8dd37a13.js",
|
|
119
120
|
"./www/build/p-e1255160.js"
|
|
120
121
|
]
|
|
@@ -149,12 +150,12 @@
|
|
|
149
150
|
"components": [
|
|
150
151
|
"mds-accordion-timer"
|
|
151
152
|
],
|
|
152
|
-
"bundleId": "p-
|
|
153
|
-
"fileName": "p-
|
|
153
|
+
"bundleId": "p-86e0d6b4",
|
|
154
|
+
"fileName": "p-86e0d6b4.entry.js",
|
|
154
155
|
"imports": [
|
|
155
156
|
"p-8dd37a13.js"
|
|
156
157
|
],
|
|
157
|
-
"originalByteSize":
|
|
158
|
+
"originalByteSize": 6394
|
|
158
159
|
}
|
|
159
160
|
],
|
|
160
161
|
"esm": [
|
|
@@ -168,7 +169,7 @@
|
|
|
168
169
|
"imports": [
|
|
169
170
|
"index-af411208.js"
|
|
170
171
|
],
|
|
171
|
-
"originalByteSize":
|
|
172
|
+
"originalByteSize": 6398
|
|
172
173
|
}
|
|
173
174
|
],
|
|
174
175
|
"es5": [
|
|
@@ -182,7 +183,7 @@
|
|
|
182
183
|
"imports": [
|
|
183
184
|
"index-af411208.js"
|
|
184
185
|
],
|
|
185
|
-
"originalByteSize":
|
|
186
|
+
"originalByteSize": 6398
|
|
186
187
|
}
|
|
187
188
|
],
|
|
188
189
|
"system": [
|
|
@@ -191,12 +192,12 @@
|
|
|
191
192
|
"components": [
|
|
192
193
|
"mds-accordion-timer"
|
|
193
194
|
],
|
|
194
|
-
"bundleId": "p-
|
|
195
|
-
"fileName": "p-
|
|
195
|
+
"bundleId": "p-4eb3ec08.system",
|
|
196
|
+
"fileName": "p-4eb3ec08.system.entry.js",
|
|
196
197
|
"imports": [
|
|
197
198
|
"p-62c48ff3.system.js"
|
|
198
199
|
],
|
|
199
|
-
"originalByteSize":
|
|
200
|
+
"originalByteSize": 7508
|
|
200
201
|
}
|
|
201
202
|
],
|
|
202
203
|
"commonjs": [
|
|
@@ -210,7 +211,7 @@
|
|
|
210
211
|
"imports": [
|
|
211
212
|
"index-0853bd56.js"
|
|
212
213
|
],
|
|
213
|
-
"originalByteSize":
|
|
214
|
+
"originalByteSize": 6445
|
|
214
215
|
}
|
|
215
216
|
]
|
|
216
217
|
},
|
|
@@ -591,6 +592,7 @@
|
|
|
591
592
|
"sourceGraph": {
|
|
592
593
|
"./src/common/aria.ts": [],
|
|
593
594
|
"./src/common/date.ts": [],
|
|
595
|
+
"./src/common/device.ts": [],
|
|
594
596
|
"./src/common/file.ts": [],
|
|
595
597
|
"./src/common/icon.ts": [],
|
|
596
598
|
"./src/common/keyboard-manager.ts": [],
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
declare const unslugName: (name: string) => string;
|
|
2
2
|
declare const setAttributeIfEmpty: (element: HTMLElement, attribute: string, value: string) => string;
|
|
3
|
+
declare const removeAttributesIf: (element: HTMLElement, attribute: string, valueCheck: string | undefined, cleanAttributes: string | string[]) => boolean;
|
|
4
|
+
declare const ifAttribute: (element: HTMLElement, attribute: string, valueCheck?: string) => boolean;
|
|
3
5
|
declare const hashValue: (value: string) => string;
|
|
4
6
|
declare const hashRandomValue: (value?: string) => string;
|
|
5
|
-
export {
|
|
7
|
+
export { hashRandomValue, hashValue, removeAttributesIf, setAttributeIfEmpty, ifAttribute, unslugName, };
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
+
declare const typographyTagDictionary: string[];
|
|
2
|
+
declare const typographyHeadingTagDictionary: string[];
|
|
1
3
|
declare const truncateDictionary: string[];
|
|
2
|
-
export { truncateDictionary, };
|
|
4
|
+
export { truncateDictionary, typographyHeadingTagDictionary, typographyTagDictionary, };
|
|
@@ -1 +1,3 @@
|
|
|
1
|
+
export type TypographyTagType = 'abbr' | 'address' | 'article' | 'b' | 'bdo' | 'blockquote' | 'cite' | 'code' | 'dd' | 'del' | 'details' | 'dfn' | 'div' | 'dl' | 'dt' | 'em' | 'figcaption' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'i' | 'ins' | 'kbd' | 'label' | 'legend' | 'li' | 'mark' | 'ol' | 'p' | 'pre' | 'q' | 'rb' | 'rt' | 'ruby' | 's' | 'samp' | 'small' | 'span' | 'strong' | 'sub' | 'summary' | 'sup' | 'time' | 'u' | 'ul' | 'var';
|
|
2
|
+
export type TypographyHeadingTagType = 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6';
|
|
1
3
|
export type TypographyTruncateType = 'all' | 'none' | 'word';
|
package/documentation.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"timestamp": "2024-
|
|
2
|
+
"timestamp": "2024-12-04T15:30:05",
|
|
3
3
|
"compiler": {
|
|
4
4
|
"name": "@stencil/core",
|
|
5
5
|
"version": "4.22.2",
|
|
@@ -562,6 +562,11 @@
|
|
|
562
562
|
"docstring": "",
|
|
563
563
|
"path": "src/components/mds-push-notification/meta/event-detail.ts"
|
|
564
564
|
},
|
|
565
|
+
"src/type/text.ts::TypographyHeadingTagType": {
|
|
566
|
+
"declaration": "export type TypographyHeadingTagType =\n | 'h1'\n | 'h2'\n | 'h3'\n | 'h4'\n | 'h5'\n | 'h6'",
|
|
567
|
+
"docstring": "",
|
|
568
|
+
"path": "src/type/text.ts"
|
|
569
|
+
},
|
|
565
570
|
"src/components/mds-stepper-bar/meta/event-detail.ts::MdsStepperBarEventDetail": {
|
|
566
571
|
"declaration": "export interface MdsStepperBarEventDetail {\n step: number\n value: string\n}",
|
|
567
572
|
"docstring": "",
|
|
@@ -593,7 +598,7 @@
|
|
|
593
598
|
"path": "src/components/mds-tab-item/meta/event-detail.ts"
|
|
594
599
|
},
|
|
595
600
|
"src/components/mds-table-header-cell/meta/types.ts::SortDirectionType": {
|
|
596
|
-
"declaration": "export type SortDirectionType =\n | '
|
|
601
|
+
"declaration": "export type SortDirectionType =\n | 'ascending'\n | 'descending'\n | 'none'",
|
|
597
602
|
"docstring": "",
|
|
598
603
|
"path": "src/components/mds-table-header-cell/meta/types.ts"
|
|
599
604
|
},
|
|
@@ -602,10 +607,10 @@
|
|
|
602
607
|
"docstring": "",
|
|
603
608
|
"path": "src/components/mds-text/meta/types.ts"
|
|
604
609
|
},
|
|
605
|
-
"src/
|
|
610
|
+
"src/type/text.ts::TypographyTagType": {
|
|
606
611
|
"declaration": "export type TypographyTagType =\n | 'abbr'\n | 'address'\n | 'article'\n | 'b'\n | 'bdo'\n | 'blockquote'\n | 'cite'\n | 'code'\n | 'dd'\n | 'del'\n | 'details'\n | 'dfn'\n | 'div'\n | 'dl'\n | 'dt'\n | 'em'\n | 'figcaption'\n | 'h1'\n | 'h2'\n | 'h3'\n | 'h4'\n | 'h5'\n | 'h6'\n | 'i'\n | 'ins'\n | 'kbd'\n | 'label'\n | 'legend'\n | 'li'\n | 'mark'\n | 'ol'\n | 'p'\n | 'pre'\n | 'q'\n | 'rb'\n | 'rt'\n | 'ruby'\n | 's'\n | 'samp'\n | 'small'\n | 'span'\n | 'strong'\n | 'sub'\n | 'summary'\n | 'sup'\n | 'time'\n | 'u'\n | 'ul'\n | 'var'",
|
|
607
612
|
"docstring": "",
|
|
608
|
-
"path": "src/
|
|
613
|
+
"path": "src/type/text.ts"
|
|
609
614
|
},
|
|
610
615
|
"src/type/variant.ts::ThemeLuminanceVariantType": {
|
|
611
616
|
"declaration": "export type ThemeLuminanceVariantType =\n | 'dark'\n | 'light'",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@maggioli-design-system/mds-accordion-timer",
|
|
3
|
-
"version": "4.0.
|
|
3
|
+
"version": "4.0.1",
|
|
4
4
|
"description": "mds-accordion-timer is a web-component from Magma Design System, built with StencilJS, TypeScript, Storybook. It's based on the web-component standard and it's designed to be agnostic from the JavaScript framework you are using.",
|
|
5
5
|
"main": "dist/index.cjs.js",
|
|
6
6
|
"module": "dist/index.js",
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
"test": "stencil test --spec --e2e"
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"@maggioli-design-system/mds-accordion-timer-item": "4.0.
|
|
27
|
+
"@maggioli-design-system/mds-accordion-timer-item": "4.0.1",
|
|
28
28
|
"@maggioli-design-system/styles": "15.5.0",
|
|
29
29
|
"@stencil/core": "4.22.2"
|
|
30
30
|
},
|
package/src/common/aria.ts
CHANGED
|
@@ -20,6 +20,24 @@ const setAttributeIfEmpty = (element: HTMLElement, attribute: string, value: str
|
|
|
20
20
|
return value
|
|
21
21
|
}
|
|
22
22
|
|
|
23
|
+
const removeAttributesIf = (element: HTMLElement, attribute: string, valueCheck: string = 'true', cleanAttributes: string | string[]): boolean => {
|
|
24
|
+
if (ifAttribute(element, attribute, valueCheck)) {
|
|
25
|
+
const attributesList = Array.isArray(cleanAttributes) ? cleanAttributes : [cleanAttributes]
|
|
26
|
+
attributesList.forEach(attributeToRemove => {
|
|
27
|
+
element.removeAttribute(attributeToRemove)
|
|
28
|
+
})
|
|
29
|
+
return true
|
|
30
|
+
}
|
|
31
|
+
return false
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
const ifAttribute = (element: HTMLElement, attribute: string, valueCheck: string = 'true'): boolean => {
|
|
35
|
+
if (element.hasAttribute(attribute) && element.getAttribute(attribute) === valueCheck) {
|
|
36
|
+
return true
|
|
37
|
+
}
|
|
38
|
+
return false
|
|
39
|
+
}
|
|
40
|
+
|
|
23
41
|
const hashValue = (value: string): string => `${value}-${hash(value)}`
|
|
24
42
|
|
|
25
43
|
const hashRandomValue = (value?: string): string => {
|
|
@@ -32,8 +50,10 @@ const hashRandomValue = (value?: string): string => {
|
|
|
32
50
|
}
|
|
33
51
|
|
|
34
52
|
export {
|
|
35
|
-
unslugName,
|
|
36
|
-
setAttributeIfEmpty,
|
|
37
53
|
hashRandomValue,
|
|
38
54
|
hashValue,
|
|
55
|
+
removeAttributesIf,
|
|
56
|
+
setAttributeIfEmpty,
|
|
57
|
+
ifAttribute,
|
|
58
|
+
unslugName,
|
|
39
59
|
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
const isMobileDevice = (): boolean => {
|
|
2
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
3
|
+
const userAgent = navigator.userAgent || navigator.vendor || (window as any).opera
|
|
4
|
+
return /android|iphone|ipad|ipod|blackberry|iemobile|opera mini/i.test(userAgent)
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
export {
|
|
8
|
+
isMobileDevice,
|
|
9
|
+
}
|
|
@@ -36,14 +36,14 @@ export class KeyboardManager {
|
|
|
36
36
|
|
|
37
37
|
attachEscapeBehavior = (callback: () => void): void => {
|
|
38
38
|
this.escapeCallback = callback
|
|
39
|
-
if (window !== undefined) {
|
|
39
|
+
if (typeof window !== 'undefined') {
|
|
40
40
|
window.addEventListener('keydown', this.handleEscapeBehaviorDispatchEvent.bind(this))
|
|
41
41
|
}
|
|
42
42
|
}
|
|
43
43
|
|
|
44
44
|
detachEscapeBehavior = (): void => {
|
|
45
45
|
this.escapeCallback = () => { return }
|
|
46
|
-
if (window !== undefined) {
|
|
46
|
+
if (typeof window !== 'undefined') {
|
|
47
47
|
window.removeEventListener('keydown', this.handleEscapeBehaviorDispatchEvent.bind(this))
|
|
48
48
|
}
|
|
49
49
|
}
|
|
@@ -58,7 +58,9 @@ export class MdsAccordionTimer {
|
|
|
58
58
|
}
|
|
59
59
|
|
|
60
60
|
private readonly clearIntervals = (): void => {
|
|
61
|
-
window
|
|
61
|
+
if (typeof window !== 'undefined') {
|
|
62
|
+
window.clearInterval(this.timeChecker)
|
|
63
|
+
}
|
|
62
64
|
this.timeChecker = 0
|
|
63
65
|
}
|
|
64
66
|
|
|
@@ -77,16 +79,18 @@ export class MdsAccordionTimer {
|
|
|
77
79
|
}
|
|
78
80
|
|
|
79
81
|
private readonly addTimeListener = (): void => {
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
this.selectedItem
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
82
|
+
if (typeof window !== 'undefined') {
|
|
83
|
+
this.timeChecker = window.setInterval(() => {
|
|
84
|
+
const progress = this.progress()
|
|
85
|
+
if (this.selectedItem !== undefined) {
|
|
86
|
+
this.selectedItem.progress = progress
|
|
87
|
+
}
|
|
88
|
+
if (progress === 1) {
|
|
89
|
+
this.selectedItem.progress = 0
|
|
90
|
+
this.startNext()
|
|
91
|
+
}
|
|
92
|
+
}, 100)
|
|
93
|
+
}
|
|
90
94
|
}
|
|
91
95
|
|
|
92
96
|
private readonly beginningTime = (): number => {
|
|
@@ -11,64 +11,123 @@ interface ExtensionInfo {
|
|
|
11
11
|
}
|
|
12
12
|
|
|
13
13
|
const fileExtensionsDictionary: FileExtenstion = {
|
|
14
|
-
'7z': { format: 'archive', description: '
|
|
15
|
-
ace: { format: 'archive', description: '
|
|
16
|
-
ai: { format: 'vector', description: '
|
|
17
|
-
dart: { format: 'code', description: '
|
|
18
|
-
db: { format: 'data', description: '
|
|
19
|
-
default: { format: 'attachment', description: '
|
|
20
|
-
dmg: { format: 'executable', description: '
|
|
21
|
-
doc: { format: 'text', description: '
|
|
22
|
-
docm: { format: 'text', description: '
|
|
23
|
-
docx: { format: 'text', description: '
|
|
24
|
-
eml: { format: 'email', description: '
|
|
25
|
-
eps: { format: 'vector', description: '
|
|
26
|
-
exe: { format: 'executable', description: '
|
|
27
|
-
flac: { format: 'audio', description: '
|
|
28
|
-
gif: { format: 'image', description: '
|
|
29
|
-
htm: { format: 'markup', description: '
|
|
30
|
-
heic: { format: 'image', description: '
|
|
31
|
-
html: { format: 'markup', description: '
|
|
32
|
-
jpe: { format: 'image', description: '
|
|
33
|
-
jpeg: { format: 'image', description: '
|
|
34
|
-
jpg: { format: 'image', description: '
|
|
35
|
-
js: { format: 'code', description: '
|
|
36
|
-
json: { format: 'data', description: '
|
|
37
|
-
jsx: { format: 'code', description: '
|
|
38
|
-
m2v: { format: 'video', description: '
|
|
39
|
-
mp2: { format: 'audio', description: '
|
|
40
|
-
mp3: { format: 'audio', description: '
|
|
41
|
-
mp4: { format: 'video', description: '
|
|
42
|
-
mp4v: { format: 'video', description: '
|
|
43
|
-
mpeg: { format: 'video', description: '
|
|
44
|
-
mpg4: { format: 'video', description: '
|
|
45
|
-
mpg: { format: 'video', description: '
|
|
46
|
-
mpga: { format: 'audio', description: '
|
|
47
|
-
odp: { format: 'slide', description: '
|
|
48
|
-
ods: { format: 'spreadsheet', description: '
|
|
49
|
-
odt: { format: 'text', description: '
|
|
50
|
-
pdf: { format: 'document', description: '
|
|
51
|
-
php: { format: 'code', description: '
|
|
52
|
-
png: { format: 'image', description: '
|
|
53
|
-
ppt: { format: 'slide', description: '
|
|
54
|
-
rar: { format: 'archive', description: '
|
|
55
|
-
rtf: { format: 'text', description: '
|
|
56
|
-
sass: { format: 'code', description: '
|
|
57
|
-
shtml: { format: 'markup', description: '
|
|
58
|
-
svg: { format: 'vector', description: '
|
|
59
|
-
tar: { format: 'archive', description: '
|
|
60
|
-
tiff: { format: 'image', description: '
|
|
61
|
-
ts: { format: 'code', description: '
|
|
62
|
-
tsx: { format: 'code', description: '
|
|
63
|
-
txt: { format: 'text', description: '
|
|
64
|
-
wav: { format: 'audio', description: '
|
|
65
|
-
webp: { format: 'image', description: '
|
|
66
|
-
xar: { format: 'archive', description: '
|
|
67
|
-
xls: { format: 'spreadsheet', description: '
|
|
68
|
-
xlsx: { format: 'spreadsheet', description: '
|
|
69
|
-
zip: { format: 'archive', description: '
|
|
14
|
+
'7z': { format: 'archive', description: 'compressedArchive' },
|
|
15
|
+
ace: { format: 'archive', description: 'compressedArchive' },
|
|
16
|
+
ai: { format: 'vector', description: 'fileAI' },
|
|
17
|
+
dart: { format: 'code', description: 'dart' },
|
|
18
|
+
db: { format: 'data', description: 'fileDB' },
|
|
19
|
+
default: { format: 'attachment', description: 'unknown' },
|
|
20
|
+
dmg: { format: 'executable', description: 'appleDiskImage' },
|
|
21
|
+
doc: { format: 'text', description: 'documentMS' },
|
|
22
|
+
docm: { format: 'text', description: 'documentMS' },
|
|
23
|
+
docx: { format: 'text', description: 'compressedDocumentMS' },
|
|
24
|
+
eml: { format: 'email', description: 'email' },
|
|
25
|
+
eps: { format: 'vector', description: 'fileEPS' },
|
|
26
|
+
exe: { format: 'executable', description: 'fileEXE' },
|
|
27
|
+
flac: { format: 'audio', description: 'uncompressedAudio' },
|
|
28
|
+
gif: { format: 'image', description: 'compressedImage', preview: true },
|
|
29
|
+
htm: { format: 'markup', description: 'documentWeb' },
|
|
30
|
+
heic: { format: 'image', description: 'imageHEFF' },
|
|
31
|
+
html: { format: 'markup', description: 'documentWeb' },
|
|
32
|
+
jpe: { format: 'image', description: 'compressedImage', preview: true },
|
|
33
|
+
jpeg: { format: 'image', description: 'compressedImage', preview: true },
|
|
34
|
+
jpg: { format: 'image', description: 'compressedImage', preview: true },
|
|
35
|
+
js: { format: 'code', description: 'fileJS' },
|
|
36
|
+
json: { format: 'data', description: 'fileJSON' },
|
|
37
|
+
jsx: { format: 'code', description: 'fileJS' },
|
|
38
|
+
m2v: { format: 'video', description: 'videoSD' },
|
|
39
|
+
mp2: { format: 'audio', description: 'compressedAudio' },
|
|
40
|
+
mp3: { format: 'audio', description: 'compressedAudio' },
|
|
41
|
+
mp4: { format: 'video', description: 'videoHD' },
|
|
42
|
+
mp4v: { format: 'video', description: 'videoHD' },
|
|
43
|
+
mpeg: { format: 'video', description: 'videoSD' },
|
|
44
|
+
mpg4: { format: 'video', description: 'videoSD' },
|
|
45
|
+
mpg: { format: 'video', description: 'videoSD' },
|
|
46
|
+
mpga: { format: 'audio', description: 'compressedAudio' },
|
|
47
|
+
odp: { format: 'slide', description: 'slideLO' },
|
|
48
|
+
ods: { format: 'spreadsheet', description: 'spreadsheetLO' },
|
|
49
|
+
odt: { format: 'text', description: 'documentLO' },
|
|
50
|
+
pdf: { format: 'document', description: 'documentAdobe' },
|
|
51
|
+
php: { format: 'code', description: 'filePHP' },
|
|
52
|
+
png: { format: 'image', description: 'imagePNG', preview: true },
|
|
53
|
+
ppt: { format: 'slide', description: 'slidePowerPoint' },
|
|
54
|
+
rar: { format: 'archive', description: 'compressedArchive' },
|
|
55
|
+
rtf: { format: 'text', description: 'documentRTF' },
|
|
56
|
+
sass: { format: 'code', description: 'fileSASS' },
|
|
57
|
+
shtml: { format: 'markup', description: 'documentWeb' },
|
|
58
|
+
svg: { format: 'vector', description: 'imageSVG', preview: true },
|
|
59
|
+
tar: { format: 'archive', description: 'uncompressedArchive' },
|
|
60
|
+
tiff: { format: 'image', description: 'imageTIFF' },
|
|
61
|
+
ts: { format: 'code', description: 'fileTS' },
|
|
62
|
+
tsx: { format: 'code', description: 'fileTSX' },
|
|
63
|
+
txt: { format: 'text', description: 'documentTXT' },
|
|
64
|
+
wav: { format: 'audio', description: 'uncompressedAudio' },
|
|
65
|
+
webp: { format: 'image', description: 'imageWEBP', preview: true },
|
|
66
|
+
xar: { format: 'archive', description: 'compressedArchive' },
|
|
67
|
+
xls: { format: 'spreadsheet', description: 'spreadsheetMS' },
|
|
68
|
+
xlsx: { format: 'spreadsheet', description: 'spreadsheetMS' },
|
|
69
|
+
zip: { format: 'archive', description: 'compressedArchive' },
|
|
70
70
|
}
|
|
71
71
|
|
|
72
|
+
// const fileExtensionsDictionary: FileExtenstion = {
|
|
73
|
+
// '7z': { format: 'archive', description: 'Archivio compresso' },
|
|
74
|
+
// ace: { format: 'archive', description: 'Archivio compresso' },
|
|
75
|
+
// ai: { format: 'vector', description: 'Vettoriale Adobe Illustrator' },
|
|
76
|
+
// dart: { format: 'code', description: 'Dart' },
|
|
77
|
+
// db: { format: 'data', description: 'File di database' },
|
|
78
|
+
// default: { format: 'attachment', description: 'Formato sconosciuto' },
|
|
79
|
+
// dmg: { format: 'executable', description: 'Apple Disk Image' },
|
|
80
|
+
// doc: { format: 'text', description: 'Documento Microsoft Word' },
|
|
81
|
+
// docm: { format: 'text', description: 'Documento Microsoft Word' },
|
|
82
|
+
// docx: { format: 'text', description: 'Documento Microsoft Word Compresso' },
|
|
83
|
+
// eml: { format: 'email', description: 'E-mail di posta elettronica' },
|
|
84
|
+
// eps: { format: 'vector', description: 'Vettoriale Corel Draw' },
|
|
85
|
+
// exe: { format: 'executable', description: 'File eseguibile Windows' },
|
|
86
|
+
// flac: { format: 'audio', description: 'Audio non compresso' },
|
|
87
|
+
// gif: { format: 'image', description: 'Immagine compressa', preview: true },
|
|
88
|
+
// htm: { format: 'markup', description: 'Pagina web' },
|
|
89
|
+
// heic: { format: 'image', description: 'High Efficiency Image File Format' },
|
|
90
|
+
// html: { format: 'markup', description: 'Pagina web' },
|
|
91
|
+
// jpe: { format: 'image', description: 'Immagine compressa', preview: true },
|
|
92
|
+
// jpeg: { format: 'image', description: 'Immagine compressa', preview: true },
|
|
93
|
+
// jpg: { format: 'image', description: 'Immagine compressa', preview: true },
|
|
94
|
+
// js: { format: 'code', description: 'JavaScript' },
|
|
95
|
+
// json: { format: 'data', description: 'JavaScript Object Notation' },
|
|
96
|
+
// jsx: { format: 'code', description: 'JavaScript' },
|
|
97
|
+
// m2v: { format: 'video', description: 'Filmato SD' },
|
|
98
|
+
// mp2: { format: 'audio', description: 'Audio compresso' },
|
|
99
|
+
// mp3: { format: 'audio', description: 'Audio compresso' },
|
|
100
|
+
// mp4: { format: 'video', description: 'Filmato HD' },
|
|
101
|
+
// mp4v: { format: 'video', description: 'Filmato HD' },
|
|
102
|
+
// mpeg: { format: 'video', description: 'Filmato SD' },
|
|
103
|
+
// mpg4: { format: 'video', description: 'Filmato SD' },
|
|
104
|
+
// mpg: { format: 'video', description: 'Filmato SD' },
|
|
105
|
+
// mpga: { format: 'audio', description: 'Audio compresso' },
|
|
106
|
+
// odp: { format: 'slide', description: 'Slide di presentazione LibreOffice' },
|
|
107
|
+
// ods: { format: 'spreadsheet', description: 'Foglio di calcolo LibreOffice' },
|
|
108
|
+
// odt: { format: 'text', description: 'File di testo LibreOffice' },
|
|
109
|
+
// pdf: { format: 'document', description: 'Documento Adobe' },
|
|
110
|
+
// php: { format: 'code', description: 'Hypertext Preprocessor' },
|
|
111
|
+
// png: { format: 'image', description: 'Immagine Portable Network Graphics', preview: true },
|
|
112
|
+
// ppt: { format: 'slide', description: 'Slide di presentazione PowerPoint' },
|
|
113
|
+
// rar: { format: 'archive', description: 'Archivio compresso' },
|
|
114
|
+
// rtf: { format: 'text', description: 'Documento di testo Rich Text Format' },
|
|
115
|
+
// sass: { format: 'code', description: 'Syntactically Awesome StyleSheets' },
|
|
116
|
+
// shtml: { format: 'markup', description: 'Pagina web' },
|
|
117
|
+
// svg: { format: 'vector', description: 'Scalable Vector Graphics', preview: true },
|
|
118
|
+
// tar: { format: 'archive', description: 'Archivio non compresso' },
|
|
119
|
+
// tiff: { format: 'image', description: 'Tag Image File Format' },
|
|
120
|
+
// ts: { format: 'code', description: 'TypeScript' },
|
|
121
|
+
// tsx: { format: 'code', description: 'TypeScript Extended Syntax' },
|
|
122
|
+
// txt: { format: 'text', description: 'Documento di testo non formattato' },
|
|
123
|
+
// wav: { format: 'audio', description: 'Audio non compresso' },
|
|
124
|
+
// webp: { format: 'image', description: 'Immagine Web Picture', preview: true },
|
|
125
|
+
// xar: { format: 'archive', description: 'Archivio compresso' },
|
|
126
|
+
// xls: { format: 'spreadsheet', description: 'Foglio di calcolo Office' },
|
|
127
|
+
// xlsx: { format: 'spreadsheet', description: 'Foglio di calcolo Office' },
|
|
128
|
+
// zip: { format: 'archive', description: 'Archivio compresso' },
|
|
129
|
+
// }
|
|
130
|
+
|
|
72
131
|
const genericMimeToExt: Map<string, string[]> = new Map([
|
|
73
132
|
['image', ['.png', '.jpg', '.jpeg', '.tiff', '.webp', '.jpe', '.gif', '.heic']],
|
|
74
133
|
['audio', ['.mp2', '.mp3', '.mpga', '.wav', '.flac']],
|
package/src/dictionary/text.ts
CHANGED
|
@@ -1,3 +1,65 @@
|
|
|
1
|
+
const typographyTagDictionary = [
|
|
2
|
+
'abbr',
|
|
3
|
+
'address',
|
|
4
|
+
'article',
|
|
5
|
+
'b',
|
|
6
|
+
'bdo',
|
|
7
|
+
'blockquote',
|
|
8
|
+
'cite',
|
|
9
|
+
'code',
|
|
10
|
+
'dd',
|
|
11
|
+
'del',
|
|
12
|
+
'details',
|
|
13
|
+
'dfn',
|
|
14
|
+
'div',
|
|
15
|
+
'dl',
|
|
16
|
+
'dt',
|
|
17
|
+
'em',
|
|
18
|
+
'figcaption',
|
|
19
|
+
'h1',
|
|
20
|
+
'h2',
|
|
21
|
+
'h3',
|
|
22
|
+
'h4',
|
|
23
|
+
'h5',
|
|
24
|
+
'h6',
|
|
25
|
+
'i',
|
|
26
|
+
'ins',
|
|
27
|
+
'kbd',
|
|
28
|
+
'label',
|
|
29
|
+
'legend',
|
|
30
|
+
'li',
|
|
31
|
+
'mark',
|
|
32
|
+
'ol',
|
|
33
|
+
'p',
|
|
34
|
+
'pre',
|
|
35
|
+
'q',
|
|
36
|
+
'rb',
|
|
37
|
+
'rt',
|
|
38
|
+
'ruby',
|
|
39
|
+
's',
|
|
40
|
+
'samp',
|
|
41
|
+
'small',
|
|
42
|
+
'span',
|
|
43
|
+
'strong',
|
|
44
|
+
'sub',
|
|
45
|
+
'summary',
|
|
46
|
+
'sup',
|
|
47
|
+
'time',
|
|
48
|
+
'u',
|
|
49
|
+
'ul',
|
|
50
|
+
'var',
|
|
51
|
+
]
|
|
52
|
+
|
|
53
|
+
const typographyHeadingTagDictionary = [
|
|
54
|
+
'h1',
|
|
55
|
+
'h2',
|
|
56
|
+
'h3',
|
|
57
|
+
'h4',
|
|
58
|
+
'h5',
|
|
59
|
+
'h6',
|
|
60
|
+
]
|
|
61
|
+
|
|
62
|
+
|
|
1
63
|
const truncateDictionary = [
|
|
2
64
|
'all',
|
|
3
65
|
'none',
|
|
@@ -6,4 +68,6 @@ const truncateDictionary = [
|
|
|
6
68
|
|
|
7
69
|
export {
|
|
8
70
|
truncateDictionary,
|
|
71
|
+
typographyHeadingTagDictionary,
|
|
72
|
+
typographyTagDictionary,
|
|
9
73
|
}
|
package/src/fixtures/icons.json
CHANGED
|
@@ -35,6 +35,7 @@
|
|
|
35
35
|
"mgg/adv-denied",
|
|
36
36
|
"mgg/ai-brain",
|
|
37
37
|
"mgg/ai-brain-outline",
|
|
38
|
+
"mgg/ai-human",
|
|
38
39
|
"mgg/ai-message",
|
|
39
40
|
"mgg/ai-outline",
|
|
40
41
|
"mgg/ai-status-completed",
|
|
@@ -111,6 +112,8 @@
|
|
|
111
112
|
"mgg/factory",
|
|
112
113
|
"mgg/farmer",
|
|
113
114
|
"mgg/field",
|
|
115
|
+
"mgg/file-certificate",
|
|
116
|
+
"mgg/file-clock",
|
|
114
117
|
"mgg/file-download",
|
|
115
118
|
"mgg/file-folder-tree",
|
|
116
119
|
"mgg/file-folder-tree-open",
|
|
@@ -132,6 +135,7 @@
|
|
|
132
135
|
"mgg/finance-euro-cashback",
|
|
133
136
|
"mgg/fit-horizontal",
|
|
134
137
|
"mgg/fit-vertical",
|
|
138
|
+
"mgg/fontawesome-torii-gate",
|
|
135
139
|
"mgg/forwarded-with-a-single-sending",
|
|
136
140
|
"mgg/fullscreen-on-alt",
|
|
137
141
|
"mgg/google-book-closed",
|
|
@@ -141,6 +145,7 @@
|
|
|
141
145
|
"mgg/google-book-opening",
|
|
142
146
|
"mgg/google-book-opening-outline",
|
|
143
147
|
"mgg/google-check-small",
|
|
148
|
+
"mgg/google-drag-pan",
|
|
144
149
|
"mgg/google-experiment",
|
|
145
150
|
"mgg/google-face-retouching-off",
|
|
146
151
|
"mgg/google-hub",
|
|
@@ -320,6 +325,7 @@
|
|
|
320
325
|
"mi/baseline/book",
|
|
321
326
|
"mi/baseline/border-all",
|
|
322
327
|
"mi/baseline/broken-image",
|
|
328
|
+
"mi/baseline/call",
|
|
323
329
|
"mi/baseline/cancel",
|
|
324
330
|
"mi/baseline/category",
|
|
325
331
|
"mi/baseline/check-box",
|
|
@@ -329,6 +335,7 @@
|
|
|
329
335
|
"mi/baseline/contrast",
|
|
330
336
|
"mi/baseline/css",
|
|
331
337
|
"mi/baseline/dark-mode",
|
|
338
|
+
"mi/baseline/delete",
|
|
332
339
|
"mi/baseline/description",
|
|
333
340
|
"mi/baseline/directions-run",
|
|
334
341
|
"mi/baseline/directions-walk",
|
|
@@ -360,6 +367,7 @@
|
|
|
360
367
|
"mi/baseline/remove",
|
|
361
368
|
"mi/baseline/remove-circle",
|
|
362
369
|
"mi/baseline/route",
|
|
370
|
+
"mi/baseline/send",
|
|
363
371
|
"mi/baseline/settings",
|
|
364
372
|
"mi/baseline/sports",
|
|
365
373
|
"mi/baseline/sports-soccer",
|