@contentrain/astro-kit 0.1.1 → 0.2.0
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/README.md +20 -3
- package/catalog.json +243 -2
- package/components/_shared/Button.astro +1 -1
- package/components/breadcrumb/Breadcrumb.astro +1 -1
- package/components/card-grid/CardGrid.astro +3 -3
- package/components/contact-form/ContactForm.astro +1 -1
- package/components/cta/Cta.astro +1 -1
- package/components/embed/Embed.astro +104 -0
- package/components/embed/embed.ts +106 -0
- package/components/embed/fixtures.json +34 -0
- package/components/embed/meta.json +32 -0
- package/components/faq/Faq.astro +2 -2
- package/components/footer/Footer.astro +4 -4
- package/components/footer/meta.json +107 -14
- package/components/gallery/Gallery.astro +3 -3
- package/components/header/Header.astro +1 -1
- package/components/hero/Hero.astro +12 -5
- package/components/hero/fixtures.json +21 -0
- package/components/hero/meta.json +8 -0
- package/components/nav/Nav.astro +4 -2
- package/components/nav/meta.json +86 -13
- package/components/newsletter/Newsletter.astro +110 -0
- package/components/newsletter/fixtures.json +6 -0
- package/components/newsletter/meta.json +105 -0
- package/components/newsletter/newsletter.ts +73 -0
- package/components/pagination/Pagination.astro +1 -1
- package/components/post-card/PostCard.astro +2 -2
- package/components/slider/Slider.astro +3 -3
- package/components/tabs/Tabs.astro +2 -2
- package/components/testimonial/Testimonial.astro +1 -1
- package/dist/index.d.mts +11 -4
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +19 -7
- package/dist/index.mjs.map +1 -1
- package/mapping/classic.json +91 -1
- package/mapping/divi.json +22 -1
- package/mapping/elementor.json +46 -1
- package/mapping/gutenberg.json +65 -3
- package/package.json +2 -2
package/mapping/divi.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"format": "astro-kit-mapping@1",
|
|
3
3
|
"builder": "divi",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "4",
|
|
5
5
|
"fallback": "prose",
|
|
6
6
|
"rules": [
|
|
7
7
|
{
|
|
@@ -290,6 +290,27 @@
|
|
|
290
290
|
"props": {
|
|
291
291
|
"html": "html:"
|
|
292
292
|
}
|
|
293
|
+
},
|
|
294
|
+
{
|
|
295
|
+
"match": "divi/et_pb_video",
|
|
296
|
+
"component": "embed",
|
|
297
|
+
"props": {
|
|
298
|
+
"url": "attr:src",
|
|
299
|
+
"playLabel": "ui:embed.play",
|
|
300
|
+
"showLabel": "ui:embed.show"
|
|
301
|
+
}
|
|
302
|
+
},
|
|
303
|
+
{
|
|
304
|
+
"match": "divi/et_pb_map",
|
|
305
|
+
"component": "embed",
|
|
306
|
+
"variant": {
|
|
307
|
+
"aspect": "map"
|
|
308
|
+
},
|
|
309
|
+
"props": {
|
|
310
|
+
"address": "attr:address",
|
|
311
|
+
"playLabel": "ui:embed.play",
|
|
312
|
+
"showLabel": "ui:embed.show"
|
|
313
|
+
}
|
|
293
314
|
}
|
|
294
315
|
]
|
|
295
316
|
}
|
package/mapping/elementor.json
CHANGED
|
@@ -1,8 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"format": "astro-kit-mapping@1",
|
|
3
3
|
"builder": "elementor",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "5",
|
|
5
5
|
"fallback": "prose",
|
|
6
|
+
"defaults": {
|
|
7
|
+
"elementor/video": {
|
|
8
|
+
"video_type": "youtube"
|
|
9
|
+
}
|
|
10
|
+
},
|
|
6
11
|
"rules": [
|
|
7
12
|
{
|
|
8
13
|
"match": "elementor/theme-site-logo",
|
|
@@ -317,6 +322,46 @@
|
|
|
317
322
|
"props": {
|
|
318
323
|
"html": "html:"
|
|
319
324
|
}
|
|
325
|
+
},
|
|
326
|
+
{
|
|
327
|
+
"match": "elementor/video",
|
|
328
|
+
"when": {
|
|
329
|
+
"attr": {
|
|
330
|
+
"video_type": "youtube"
|
|
331
|
+
}
|
|
332
|
+
},
|
|
333
|
+
"component": "embed",
|
|
334
|
+
"props": {
|
|
335
|
+
"url": "attr:youtube_url",
|
|
336
|
+
"playLabel": "ui:embed.play",
|
|
337
|
+
"showLabel": "ui:embed.show"
|
|
338
|
+
}
|
|
339
|
+
},
|
|
340
|
+
{
|
|
341
|
+
"match": "elementor/video",
|
|
342
|
+
"when": {
|
|
343
|
+
"attr": {
|
|
344
|
+
"video_type": "vimeo"
|
|
345
|
+
}
|
|
346
|
+
},
|
|
347
|
+
"component": "embed",
|
|
348
|
+
"props": {
|
|
349
|
+
"url": "attr:vimeo_url",
|
|
350
|
+
"playLabel": "ui:embed.play",
|
|
351
|
+
"showLabel": "ui:embed.show"
|
|
352
|
+
}
|
|
353
|
+
},
|
|
354
|
+
{
|
|
355
|
+
"match": "elementor/google_maps",
|
|
356
|
+
"component": "embed",
|
|
357
|
+
"variant": {
|
|
358
|
+
"aspect": "map"
|
|
359
|
+
},
|
|
360
|
+
"props": {
|
|
361
|
+
"address": "attr:address",
|
|
362
|
+
"playLabel": "ui:embed.play",
|
|
363
|
+
"showLabel": "ui:embed.show"
|
|
364
|
+
}
|
|
320
365
|
}
|
|
321
366
|
]
|
|
322
367
|
}
|
package/mapping/gutenberg.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"format": "astro-kit-mapping@1",
|
|
3
3
|
"builder": "gutenberg",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "4",
|
|
5
5
|
"fallback": "prose",
|
|
6
6
|
"rules": [
|
|
7
7
|
{
|
|
@@ -114,7 +114,8 @@
|
|
|
114
114
|
"each": ".wp-block-button__link",
|
|
115
115
|
"item": {
|
|
116
116
|
"label": "dom:",
|
|
117
|
-
"href": "dom:@href"
|
|
117
|
+
"href": "dom:@href",
|
|
118
|
+
"style": "class:is-style-outline=ghost|primary"
|
|
118
119
|
}
|
|
119
120
|
},
|
|
120
121
|
{
|
|
@@ -225,7 +226,8 @@
|
|
|
225
226
|
"each": ".wp-block-button__link",
|
|
226
227
|
"item": {
|
|
227
228
|
"label": "dom:",
|
|
228
|
-
"href": "dom:@href"
|
|
229
|
+
"href": "dom:@href",
|
|
230
|
+
"style": "class:is-style-outline=ghost|primary"
|
|
229
231
|
}
|
|
230
232
|
},
|
|
231
233
|
{
|
|
@@ -342,6 +344,66 @@
|
|
|
342
344
|
"html": "html:"
|
|
343
345
|
}
|
|
344
346
|
},
|
|
347
|
+
{
|
|
348
|
+
"match": "core/embed",
|
|
349
|
+
"when": {
|
|
350
|
+
"attr": {
|
|
351
|
+
"providerNameSlug": "youtube"
|
|
352
|
+
}
|
|
353
|
+
},
|
|
354
|
+
"component": "embed",
|
|
355
|
+
"props": {
|
|
356
|
+
"url": "attr:url",
|
|
357
|
+
"caption": "dom:figcaption",
|
|
358
|
+
"playLabel": "ui:embed.play",
|
|
359
|
+
"showLabel": "ui:embed.show"
|
|
360
|
+
}
|
|
361
|
+
},
|
|
362
|
+
{
|
|
363
|
+
"match": "core/embed",
|
|
364
|
+
"when": {
|
|
365
|
+
"attr": {
|
|
366
|
+
"providerNameSlug": "vimeo"
|
|
367
|
+
}
|
|
368
|
+
},
|
|
369
|
+
"component": "embed",
|
|
370
|
+
"props": {
|
|
371
|
+
"url": "attr:url",
|
|
372
|
+
"caption": "dom:figcaption",
|
|
373
|
+
"playLabel": "ui:embed.play",
|
|
374
|
+
"showLabel": "ui:embed.show"
|
|
375
|
+
}
|
|
376
|
+
},
|
|
377
|
+
{
|
|
378
|
+
"match": "core/embed",
|
|
379
|
+
"when": {
|
|
380
|
+
"attr": {
|
|
381
|
+
"providerNameSlug": "spotify"
|
|
382
|
+
}
|
|
383
|
+
},
|
|
384
|
+
"component": "embed",
|
|
385
|
+
"props": {
|
|
386
|
+
"url": "attr:url",
|
|
387
|
+
"caption": "dom:figcaption",
|
|
388
|
+
"playLabel": "ui:embed.play",
|
|
389
|
+
"showLabel": "ui:embed.show"
|
|
390
|
+
}
|
|
391
|
+
},
|
|
392
|
+
{
|
|
393
|
+
"match": "core/embed",
|
|
394
|
+
"when": {
|
|
395
|
+
"attr": {
|
|
396
|
+
"providerNameSlug": "soundcloud"
|
|
397
|
+
}
|
|
398
|
+
},
|
|
399
|
+
"component": "embed",
|
|
400
|
+
"props": {
|
|
401
|
+
"url": "attr:url",
|
|
402
|
+
"caption": "dom:figcaption",
|
|
403
|
+
"playLabel": "ui:embed.play",
|
|
404
|
+
"showLabel": "ui:embed.show"
|
|
405
|
+
}
|
|
406
|
+
},
|
|
345
407
|
{
|
|
346
408
|
"match": "core/embed",
|
|
347
409
|
"component": "prose",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@contentrain/astro-kit",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.2.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "Copy-in Astro components for Contentrain sites (shadcn model): typed props, tailwind-variants, zero JavaScript by default — with a machine-readable catalog",
|
|
6
6
|
"type": "module",
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
"mapping"
|
|
43
43
|
],
|
|
44
44
|
"dependencies": {
|
|
45
|
-
"@contentrain/types": "1.
|
|
45
|
+
"@contentrain/types": "1.25.0"
|
|
46
46
|
},
|
|
47
47
|
"devDependencies": {
|
|
48
48
|
"@types/node": "^22.10.0",
|