@htmlbricks/hb-contact-item 0.8.37 → 0.8.43

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/extra/docs.ts CHANGED
@@ -1,4 +1,5 @@
1
- import type { CssPart, CssVar, HtmlSlot, i18nLang, StyleSetup } from "@htmlbricks/hb-jsutils/main";
1
+ import type { CssPart, CssVar, HtmlSlot, i18nLang, StyleSetup, ComponentSetup } from "@htmlbricks/hb-jsutils/main";
2
+ import type { Component } from "../app/types/webcomponent.type";
2
3
 
3
4
  export const storybookArgs = {
4
5
  id: { control: { disable: true } },
@@ -20,14 +21,20 @@ export const styleSetup: StyleSetup = {
20
21
  parts: cssParts,
21
22
  };
22
23
 
23
- export const componentSetup = {
24
+ const examples: Component[] = [
25
+ {
26
+ email: { address: "dev@dariocaruso.info" },
27
+ },
28
+ ];
29
+ export const componentSetup: ComponentSetup & { examples: Component[] } = {
30
+ definitions: null,
24
31
  storybookArgs,
25
32
  styleSetup,
26
33
  htmlSlots,
27
34
  i18n: i18nLanguages,
28
- examples: [],
29
- name: "",
30
- category: "",
31
- tags: [],
35
+ examples,
36
+ name: "hb-contact-item",
37
+ category: "basic",
38
+ tags: ["basic"],
32
39
  size: {},
33
40
  };
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@htmlbricks/hb-contact-item",
3
3
  "displayName": "Svelte Contact WebComponent",
4
4
  "description": "Svelte Contact WebComponent",
5
- "version": "0.8.37",
5
+ "version": "0.8.43",
6
6
  "main": "release/release.js",
7
7
  "publishConfig": {
8
8
  "access": "public"
@@ -20,15 +20,18 @@
20
20
  "start": "sirv dist",
21
21
  "dev": "rm -rf ./dist && rollup -c -w",
22
22
  "build": "rm -rf ./dist && rollup -c",
23
- "generate-docs": "cp $PWD/dist/docs.js $PWD/dist/docs.mjs && generate-json-from-js-object --input $PWD/dist/docs.mjs --var componentSetup --output $PWD/dist/docs.type.d.json && rm $PWD/dist/docs.mjs",
24
- "generate-schema": "ts-json-schema-generator --path 'app/types/webcomponent.type.d.ts' > dist/webcomponent.type.d.json",
23
+ "generate-manifest": "npm run generate-schemes && manifester --dir $PWD",
24
+ "generate-component-schema": "ts-json-schema-generator --type 'Component' --path 'app/types/webcomponent.type.d.ts' > dist/webcomponent.type.d.json",
25
+ "generate-events-schema": "ts-json-schema-generator --type 'Events' --path 'app/types/webcomponent.type.d.ts' > dist/webcomponent_events.type.d.json",
26
+ "generate-schemes": "npm run generate-events-schema && npm run generate-component-schema",
25
27
  "copydest": "rm -rf release && mkdir -p release && mkdir -p release && cp dist/* ./release/",
26
28
  "build-extra": "tsc --moduleResolution node --module es2020 --esModuleInterop true --outDir dist --sourceMap --skipLibCheck extra/*",
27
- "build:release": "PRODUCTION=true npm run build && npm run build-extra && npm run generate-schema && npm run generate-docs && npm run copydest",
29
+ "build:release": "PRODUCTION=true npm run build && npm run build-extra && npm run generate-manifest && npm run copydest",
28
30
  "prepublish": "npm run build:release"
29
31
  },
30
32
  "devDependencies": {
31
- "@htmlbricks/hb-jsutils": "^0.8.37",
33
+ "@htmlbricks/hb-jsutils": "^0.8.43",
34
+ "@htmlbricks/manifester": "^0.0.5",
32
35
  "@rollup/plugin-alias": "^3.1.2",
33
36
  "@rollup/plugin-commonjs": "^18.0.0",
34
37
  "@rollup/plugin-json": "^4.1.0",
@@ -42,7 +45,6 @@
42
45
  "eslint": "^7.25.0",
43
46
  "eslint-plugin-jsdoc": "^33.0.0",
44
47
  "eslint-plugin-svelte3": "^3.2.0",
45
- "generate-json-from-js-object": "^0.0.17",
46
48
  "node-sass": "^6.0.1",
47
49
  "postcss": "^8.2.13",
48
50
  "postcss-load-config": "^3.0.1",
@@ -73,5 +75,5 @@
73
75
  "webcomponents"
74
76
  ],
75
77
  "contributors": [],
76
- "gitHead": "1a737cc2f90ff5f9c3bd06a155743e47329e8861"
78
+ "gitHead": "00bfec0d080db03f42972124577a880c9bf2570e"
77
79
  }
package/release/docs.js CHANGED
@@ -15,15 +15,21 @@ export var styleSetup = {
15
15
  vars: cssVars,
16
16
  parts: cssParts
17
17
  };
18
+ var examples = [
19
+ {
20
+ email: { address: "dev@dariocaruso.info" }
21
+ },
22
+ ];
18
23
  export var componentSetup = {
24
+ definitions: null,
19
25
  storybookArgs: storybookArgs,
20
26
  styleSetup: styleSetup,
21
27
  htmlSlots: htmlSlots,
22
28
  i18n: i18nLanguages,
23
- examples: [],
24
- name: "",
25
- category: "",
26
- tags: [],
29
+ examples: examples,
30
+ name: "hb-contact-item",
31
+ category: "basic",
32
+ tags: ["basic"],
27
33
  size: {}
28
34
  };
29
35
  //# sourceMappingURL=docs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"docs.js","sourceRoot":"","sources":["../extra/docs.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,IAAM,aAAa,GAAG;IAC5B,EAAE,EAAE,EAAE,OAAO,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,EAAE;IAClC,KAAK,EAAE,EAAE,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE;IACtC,OAAO,EAAE,EAAE,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE;IACxC,KAAK,EAAE,EAAE,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE;IACtC,IAAI,EAAE,EAAE,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE;IACrC,MAAM,EAAE,EAAE,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE;IACvC,YAAY,EAAE,EAAE,MAAM,EAAE,mBAAmB,EAAE;CAC7C,CAAC;AAEF,IAAM,OAAO,GAAa,EAAE,CAAC;AAC7B,MAAM,CAAC,IAAM,QAAQ,GAAc,EAAE,CAAC;AACtC,MAAM,CAAC,IAAM,SAAS,GAAe,EAAE,CAAC;AACxC,MAAM,CAAC,IAAM,aAAa,GAAe,EAAE,CAAC;AAE5C,MAAM,CAAC,IAAM,UAAU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C,KAAK,EAAE,EAAE,OAAO,EAAE,sBAAsB,EAAE;KAC1C;CACD,CAAC;AACF,MAAM,CAAC,IAAM,cAAc,GAA+C;IACzE,WAAW,EAAE,IAAI;IACjB,aAAa,eAAA;IACb,UAAU,YAAA;IACV,SAAS,WAAA;IACT,IAAI,EAAE,aAAa;IACnB,QAAQ,UAAA;IACR,IAAI,EAAE,iBAAiB;IACvB,QAAQ,EAAE,OAAO;IACjB,IAAI,EAAE,CAAC,OAAO,CAAC;IACf,IAAI,EAAE,EAAE;CACR,CAAC"}
@@ -0,0 +1,35 @@
1
+ export var storybookArgs = {
2
+ id: { control: { disable: true } },
3
+ phone: { control: { type: "object" } },
4
+ address: { control: { type: "object" } },
5
+ email: { control: { type: "object" } },
6
+ site: { control: { type: "object" } },
7
+ config: { control: { type: "object" } },
8
+ contactclick: { action: "contactClickEvent" }
9
+ };
10
+ var cssVars = [];
11
+ export var cssParts = [];
12
+ export var htmlSlots = [];
13
+ export var i18nLanguages = [];
14
+ export var styleSetup = {
15
+ vars: cssVars,
16
+ parts: cssParts
17
+ };
18
+ var examples = [
19
+ {
20
+ email: { address: "dev@dariocaruso.info" }
21
+ },
22
+ ];
23
+ export var componentSetup = {
24
+ definitions: null,
25
+ storybookArgs: storybookArgs,
26
+ styleSetup: styleSetup,
27
+ htmlSlots: htmlSlots,
28
+ i18n: i18nLanguages,
29
+ examples: examples,
30
+ name: "hb-contact-item",
31
+ category: "basic",
32
+ tags: ["basic"],
33
+ size: {}
34
+ };
35
+ //# sourceMappingURL=docs.js.map
package/release/docs.ts CHANGED
@@ -1,4 +1,5 @@
1
- import type { CssPart, CssVar, HtmlSlot, i18nLang, StyleSetup } from "@htmlbricks/hb-jsutils/main";
1
+ import type { CssPart, CssVar, HtmlSlot, i18nLang, StyleSetup, ComponentSetup } from "@htmlbricks/hb-jsutils/main";
2
+ import type { Component } from "../app/types/webcomponent.type";
2
3
 
3
4
  export const storybookArgs = {
4
5
  id: { control: { disable: true } },
@@ -20,14 +21,20 @@ export const styleSetup: StyleSetup = {
20
21
  parts: cssParts,
21
22
  };
22
23
 
23
- export const componentSetup = {
24
+ const examples: Component[] = [
25
+ {
26
+ email: { address: "dev@dariocaruso.info" },
27
+ },
28
+ ];
29
+ export const componentSetup: ComponentSetup & { examples: Component[] } = {
30
+ definitions: null,
24
31
  storybookArgs,
25
32
  styleSetup,
26
33
  htmlSlots,
27
34
  i18n: i18nLanguages,
28
- examples: [],
29
- name: "",
30
- category: "",
31
- tags: [],
35
+ examples,
36
+ name: "hb-contact-item",
37
+ category: "basic",
38
+ tags: ["basic"],
32
39
  size: {},
33
40
  };
@@ -0,0 +1,231 @@
1
+ {
2
+ "definitions": {
3
+ "events": {
4
+ "$ref": "#/definitions/Events",
5
+ "$schema": "http://json-schema.org/draft-07/schema#",
6
+ "definitions": {
7
+ "Events": {
8
+ "additionalProperties": false,
9
+ "properties": {
10
+ "contactclick": {
11
+ "additionalProperties": false,
12
+ "properties": {
13
+ "action": {
14
+ "type": "string"
15
+ },
16
+ "options": {}
17
+ },
18
+ "required": [
19
+ "action",
20
+ "options"
21
+ ],
22
+ "type": "object"
23
+ }
24
+ },
25
+ "required": [
26
+ "contactclick"
27
+ ],
28
+ "type": "object"
29
+ }
30
+ }
31
+ },
32
+ "component": {
33
+ "$ref": "#/definitions/Component",
34
+ "$schema": "http://json-schema.org/draft-07/schema#",
35
+ "definitions": {
36
+ "Component": {
37
+ "additionalProperties": false,
38
+ "properties": {
39
+ "address": {
40
+ "$ref": "#/definitions/IAddress"
41
+ },
42
+ "config": {
43
+ "$ref": "#/definitions/IConfig"
44
+ },
45
+ "email": {
46
+ "$ref": "#/definitions/IEmail"
47
+ },
48
+ "id": {
49
+ "type": "string"
50
+ },
51
+ "phone": {
52
+ "$ref": "#/definitions/IPhone"
53
+ },
54
+ "site": {
55
+ "$ref": "#/definitions/ISite"
56
+ },
57
+ "social": {
58
+ "$ref": "#/definitions/ISocial"
59
+ },
60
+ "style": {
61
+ "type": "string"
62
+ }
63
+ },
64
+ "type": "object"
65
+ },
66
+ "IAddress": {
67
+ "additionalProperties": false,
68
+ "properties": {
69
+ "address": {
70
+ "type": "string"
71
+ },
72
+ "latLang": {
73
+ "items": {
74
+ "type": "number"
75
+ },
76
+ "type": "array"
77
+ },
78
+ "mapUri": {
79
+ "type": "string"
80
+ },
81
+ "shortAddress": {
82
+ "type": "string"
83
+ }
84
+ },
85
+ "required": [
86
+ "address"
87
+ ],
88
+ "type": "object"
89
+ },
90
+ "IConfig": {
91
+ "additionalProperties": false,
92
+ "properties": {
93
+ "dispatcher": {
94
+ "type": "boolean"
95
+ },
96
+ "icon": {
97
+ "additionalProperties": false,
98
+ "properties": {
99
+ "fill": {
100
+ "type": "boolean"
101
+ }
102
+ },
103
+ "type": "object"
104
+ },
105
+ "text": {
106
+ "type": "boolean"
107
+ }
108
+ },
109
+ "type": "object"
110
+ },
111
+ "IEmail": {
112
+ "additionalProperties": false,
113
+ "properties": {
114
+ "address": {
115
+ "type": "string"
116
+ },
117
+ "mailLink": {
118
+ "type": "boolean"
119
+ }
120
+ },
121
+ "required": [
122
+ "address"
123
+ ],
124
+ "type": "object"
125
+ },
126
+ "IPhone": {
127
+ "additionalProperties": false,
128
+ "properties": {
129
+ "callOnClick": {
130
+ "type": "boolean"
131
+ },
132
+ "number": {
133
+ "type": "string"
134
+ }
135
+ },
136
+ "required": [
137
+ "number"
138
+ ],
139
+ "type": "object"
140
+ },
141
+ "ISite": {
142
+ "additionalProperties": false,
143
+ "properties": {
144
+ "label": {
145
+ "type": "string"
146
+ },
147
+ "open": {
148
+ "type": "boolean"
149
+ },
150
+ "uri": {
151
+ "type": "string"
152
+ }
153
+ },
154
+ "type": "object"
155
+ },
156
+ "ISocial": {
157
+ "additionalProperties": false,
158
+ "properties": {
159
+ "label": {
160
+ "type": "string"
161
+ },
162
+ "name": {
163
+ "type": "string"
164
+ },
165
+ "pageUri": {
166
+ "type": "string"
167
+ }
168
+ },
169
+ "required": [
170
+ "name"
171
+ ],
172
+ "type": "object"
173
+ }
174
+ }
175
+ }
176
+ },
177
+ "storybookArgs": {
178
+ "id": {
179
+ "control": {
180
+ "disable": true
181
+ }
182
+ },
183
+ "phone": {
184
+ "control": {
185
+ "type": "object"
186
+ }
187
+ },
188
+ "address": {
189
+ "control": {
190
+ "type": "object"
191
+ }
192
+ },
193
+ "email": {
194
+ "control": {
195
+ "type": "object"
196
+ }
197
+ },
198
+ "site": {
199
+ "control": {
200
+ "type": "object"
201
+ }
202
+ },
203
+ "config": {
204
+ "control": {
205
+ "type": "object"
206
+ }
207
+ },
208
+ "contactclick": {
209
+ "action": "contactClickEvent"
210
+ }
211
+ },
212
+ "styleSetup": {
213
+ "vars": [],
214
+ "parts": []
215
+ },
216
+ "htmlSlots": [],
217
+ "i18n": [],
218
+ "examples": [
219
+ {
220
+ "email": {
221
+ "address": "dev@dariocaruso.info"
222
+ }
223
+ }
224
+ ],
225
+ "name": "hb-contact-item",
226
+ "category": "basic",
227
+ "tags": [
228
+ "basic"
229
+ ],
230
+ "size": {}
231
+ }
@@ -1,4 +1,5 @@
1
1
  {
2
+ "$ref": "#/definitions/Component",
2
3
  "$schema": "http://json-schema.org/draft-07/schema#",
3
4
  "definitions": {
4
5
  "Component": {
@@ -31,29 +32,6 @@
31
32
  },
32
33
  "type": "object"
33
34
  },
34
- "Events": {
35
- "additionalProperties": false,
36
- "properties": {
37
- "contactclick": {
38
- "additionalProperties": false,
39
- "properties": {
40
- "action": {
41
- "type": "string"
42
- },
43
- "options": {}
44
- },
45
- "required": [
46
- "action",
47
- "options"
48
- ],
49
- "type": "object"
50
- }
51
- },
52
- "required": [
53
- "contactclick"
54
- ],
55
- "type": "object"
56
- },
57
35
  "IAddress": {
58
36
  "additionalProperties": false,
59
37
  "properties": {
@@ -0,0 +1,29 @@
1
+ {
2
+ "$ref": "#/definitions/Events",
3
+ "$schema": "http://json-schema.org/draft-07/schema#",
4
+ "definitions": {
5
+ "Events": {
6
+ "additionalProperties": false,
7
+ "properties": {
8
+ "contactclick": {
9
+ "additionalProperties": false,
10
+ "properties": {
11
+ "action": {
12
+ "type": "string"
13
+ },
14
+ "options": {}
15
+ },
16
+ "required": [
17
+ "action",
18
+ "options"
19
+ ],
20
+ "type": "object"
21
+ }
22
+ },
23
+ "required": [
24
+ "contactclick"
25
+ ],
26
+ "type": "object"
27
+ }
28
+ }
29
+ }
@@ -1,48 +0,0 @@
1
- {
2
- "storybookArgs": {
3
- "id": {
4
- "control": {
5
- "disable": true
6
- }
7
- },
8
- "phone": {
9
- "control": {
10
- "type": "object"
11
- }
12
- },
13
- "address": {
14
- "control": {
15
- "type": "object"
16
- }
17
- },
18
- "email": {
19
- "control": {
20
- "type": "object"
21
- }
22
- },
23
- "site": {
24
- "control": {
25
- "type": "object"
26
- }
27
- },
28
- "config": {
29
- "control": {
30
- "type": "object"
31
- }
32
- },
33
- "contactclick": {
34
- "action": "contactClickEvent"
35
- }
36
- },
37
- "styleSetup": {
38
- "vars": [],
39
- "parts": []
40
- },
41
- "htmlSlots": [],
42
- "i18n": [],
43
- "examples": [],
44
- "name": "",
45
- "category": "",
46
- "tags": [],
47
- "size": {}
48
- }