iconograph-ui 1.3.12 → 1.3.14

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.
@@ -0,0 +1,47 @@
1
+ <?xml version="1.0" encoding="UTF-8" standalone="no"?>
2
+ <svg
3
+ viewBox="0 0 32 32"
4
+ width="96px"
5
+ height="96px"
6
+ version="1.1"
7
+ id="svg4"
8
+ sodipodi:docname="icon-link.svg"
9
+ inkscape:version="1.1.2 (b8e25be833, 2022-02-05)"
10
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
11
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
12
+ xmlns="http://www.w3.org/2000/svg"
13
+ xmlns:svg="http://www.w3.org/2000/svg">
14
+ <defs
15
+ id="defs8">
16
+ <pattern
17
+ id="EMFhbasepattern"
18
+ patternUnits="userSpaceOnUse"
19
+ width="6"
20
+ height="6"
21
+ x="0"
22
+ y="0" />
23
+ </defs>
24
+ <sodipodi:namedview
25
+ id="namedview6"
26
+ pagecolor="#ffffff"
27
+ bordercolor="#111111"
28
+ borderopacity="1"
29
+ inkscape:pageshadow="0"
30
+ inkscape:pageopacity="0"
31
+ inkscape:pagecheckerboard="1"
32
+ showgrid="false"
33
+ inkscape:zoom="4.2083334"
34
+ inkscape:cx="148.27723"
35
+ inkscape:cy="63.80198"
36
+ inkscape:window-width="3200"
37
+ inkscape:window-height="1721"
38
+ inkscape:window-x="2391"
39
+ inkscape:window-y="-993"
40
+ inkscape:window-maximized="1"
41
+ inkscape:current-layer="svg4" />
42
+ <path
43
+ id="path824-4"
44
+ style="fill:#111111;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.69198"
45
+ d="M 69.191406 9.4375 C 65.649693 9.4327105 62.181876 10.653682 59.521484 13.365234 L 47.527344 25.589844 C 42.932394 30.273159 42.855313 36.156128 45.392578 41 L 50.974609 35.505859 C 50.07184 33.608314 51.284939 31.55052 52.761719 30.09375 L 64.642578 18.373047 C 67.547751 15.507237 72.899658 16.825629 76.128906 19.824219 C 79.127493 22.592145 80.30304 28.721752 77.388672 31.615234 L 66.4375 42.486328 C 64.723264 44.188273 62.603305 45.297626 61.101562 44.462891 L 55.09375 50.599609 C 61.129441 53.388427 66.684921 51.847555 70.59375 48.115234 L 82.587891 36.662109 C 88.614396 30.907734 87.432529 20.977643 81.666016 14.980469 C 78.422352 11.477313 73.745037 9.4436579 69.191406 9.4375 z M 59.005859 33.380859 C 57.888584 33.40547 56.820106 33.993391 56.017578 34.914062 C 48.867099 41.833881 41.947162 48.984482 35.027344 55.904297 C 33.182059 57.749582 32.543354 59.729953 34.333984 61.671875 C 35.968851 63.444872 38.493223 62.830254 40.332031 60.978516 L 61.238281 39.925781 C 62.915983 38.297423 63.507726 36.243873 61.595703 34.455078 C 60.772189 33.684637 59.874852 33.361718 59.005859 33.380859 z M 34.371094 44.691406 C 30.717358 44.649001 27.442121 46.15418 24.876953 48.603516 L 12.882812 60.056641 C 6.8563057 65.811016 8.0401264 75.741107 13.806641 81.738281 C 19.573153 87.966113 29.868323 89.551351 35.949219 83.353516 L 47.943359 71.128906 C 52.538309 66.445591 52.617343 60.562622 50.080078 55.71875 L 44.498047 61.212891 C 45.400816 63.110436 44.187718 65.16823 42.710938 66.625 L 30.830078 78.345703 C 27.924905 81.211513 22.571045 79.893121 19.341797 76.894531 C 16.343211 74.126605 15.169615 67.996998 18.083984 65.103516 L 29.033203 54.232422 C 30.74744 52.530477 32.869351 51.421124 34.371094 52.255859 L 40.376953 46.119141 C 38.302184 45.160484 36.284955 44.713619 34.371094 44.691406 z "
46
+ transform="scale(0.33333333)" />
47
+ </svg>
@@ -0,0 +1,47 @@
1
+ <?xml version="1.0" encoding="UTF-8" standalone="no"?>
2
+ <svg
3
+ viewBox="0 0 32 32"
4
+ width="96px"
5
+ height="96px"
6
+ version="1.1"
7
+ id="svg4"
8
+ sodipodi:docname="icon-link.svg"
9
+ inkscape:version="1.1.2 (b8e25be833, 2022-02-05)"
10
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
11
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
12
+ xmlns="http://www.w3.org/2000/svg"
13
+ xmlns:svg="http://www.w3.org/2000/svg">
14
+ <defs
15
+ id="defs8">
16
+ <pattern
17
+ id="EMFhbasepattern"
18
+ patternUnits="userSpaceOnUse"
19
+ width="6"
20
+ height="6"
21
+ x="0"
22
+ y="0" />
23
+ </defs>
24
+ <sodipodi:namedview
25
+ id="namedview6"
26
+ pagecolor="#ffffff"
27
+ bordercolor="#111111"
28
+ borderopacity="1"
29
+ inkscape:pageshadow="0"
30
+ inkscape:pageopacity="0"
31
+ inkscape:pagecheckerboard="1"
32
+ showgrid="false"
33
+ inkscape:zoom="4.2083334"
34
+ inkscape:cx="148.27723"
35
+ inkscape:cy="63.80198"
36
+ inkscape:window-width="3200"
37
+ inkscape:window-height="1721"
38
+ inkscape:window-x="2391"
39
+ inkscape:window-y="-993"
40
+ inkscape:window-maximized="1"
41
+ inkscape:current-layer="svg4" />
42
+ <path
43
+ id="path824-4"
44
+ style="fill:#ffffff;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.69198"
45
+ d="M 69.191406 9.4375 C 65.649693 9.4327105 62.181876 10.653682 59.521484 13.365234 L 47.527344 25.589844 C 42.932394 30.273159 42.855313 36.156128 45.392578 41 L 50.974609 35.505859 C 50.07184 33.608314 51.284939 31.55052 52.761719 30.09375 L 64.642578 18.373047 C 67.547751 15.507237 72.899658 16.825629 76.128906 19.824219 C 79.127493 22.592145 80.30304 28.721752 77.388672 31.615234 L 66.4375 42.486328 C 64.723264 44.188273 62.603305 45.297626 61.101562 44.462891 L 55.09375 50.599609 C 61.129441 53.388427 66.684921 51.847555 70.59375 48.115234 L 82.587891 36.662109 C 88.614396 30.907734 87.432529 20.977643 81.666016 14.980469 C 78.422352 11.477313 73.745037 9.4436579 69.191406 9.4375 z M 59.005859 33.380859 C 57.888584 33.40547 56.820106 33.993391 56.017578 34.914062 C 48.867099 41.833881 41.947162 48.984482 35.027344 55.904297 C 33.182059 57.749582 32.543354 59.729953 34.333984 61.671875 C 35.968851 63.444872 38.493223 62.830254 40.332031 60.978516 L 61.238281 39.925781 C 62.915983 38.297423 63.507726 36.243873 61.595703 34.455078 C 60.772189 33.684637 59.874852 33.361718 59.005859 33.380859 z M 34.371094 44.691406 C 30.717358 44.649001 27.442121 46.15418 24.876953 48.603516 L 12.882812 60.056641 C 6.8563057 65.811016 8.0401264 75.741107 13.806641 81.738281 C 19.573153 87.966113 29.868323 89.551351 35.949219 83.353516 L 47.943359 71.128906 C 52.538309 66.445591 52.617343 60.562622 50.080078 55.71875 L 44.498047 61.212891 C 45.400816 63.110436 44.187718 65.16823 42.710938 66.625 L 30.830078 78.345703 C 27.924905 81.211513 22.571045 79.893121 19.341797 76.894531 C 16.343211 74.126605 15.169615 67.996998 18.083984 65.103516 L 29.033203 54.232422 C 30.74744 52.530477 32.869351 51.421124 34.371094 52.255859 L 40.376953 46.119141 C 38.302184 45.160484 36.284955 44.713619 34.371094 44.691406 z "
46
+ transform="scale(0.33333333)" />
47
+ </svg>
@@ -0,0 +1,50 @@
1
+ <script>
2
+ // @ts-nocheck
3
+ export let date;
4
+ export let format;
5
+
6
+ function formatDate(date, format, locale = "fr-FR") {
7
+ if (!(date instanceof Date)) {
8
+ date = new Date(date);
9
+ }
10
+
11
+ const pad = (num, size = 2) => num.toString().padStart(size, "0");
12
+
13
+ // Build localized strings
14
+ const dayNameLong = new Intl.DateTimeFormat(locale, { weekday: "long" }).format(date);
15
+ const dayNameShort = new Intl.DateTimeFormat(locale, { weekday: "short" }).format(date);
16
+ const monthNameLong = new Intl.DateTimeFormat(locale, { month: "long" }).format(date);
17
+ const monthNameShort = new Intl.DateTimeFormat(locale, { month: "short" }).format(date);
18
+
19
+ const map = {
20
+ YYYY: date.getFullYear(),
21
+ YY: String(date.getFullYear()).slice(-2),
22
+ MM: pad(date.getMonth() + 1),
23
+ M: date.getMonth() + 1,
24
+ DD: pad(date.getDate()),
25
+ D: date.getDate(),
26
+ dd: pad(date.getDate()),
27
+ HH: pad(date.getHours()),
28
+ H: date.getHours(),
29
+ mm: pad(date.getMinutes()),
30
+ m: date.getMinutes(),
31
+ ss: pad(date.getSeconds()),
32
+ s: date.getSeconds(),
33
+ dddd: dayNameLong, // ex: "mardi"
34
+ ddd: dayNameShort, // ex: "mar."
35
+ MMMM: monthNameLong, // ex: "septembre"
36
+ MMM: monthNameShort, // ex: "sept."
37
+ };
38
+
39
+ return format.replace(
40
+ /\$\{(YYYY|YY|MM|M|DD|D|dd|HH|H|mm|m|ss|s|dddd|ddd|MMMM|MMM)\}/g,
41
+ (_, token) => map[token]
42
+ );
43
+ }
44
+
45
+ // console.log(formatDate(d, "Le ${dddd} ${dd} ${MMMM} ${YYYY} à ${HH}h${mm}", "fr-FR"));
46
+ // console.log(formatDate(d, "${ddd} ${D}/${M}/${YY}", "fr-FR"));
47
+
48
+ </script>
49
+
50
+ {formatDate(date, format)}
@@ -0,0 +1,24 @@
1
+ <script>
2
+ import successIcon from '../assets/icons/icon-success.svg?url';
3
+
4
+ export let uri;
5
+ export let label;
6
+ export let icon = false;
7
+
8
+ </script>
9
+
10
+ <a href="{uri}" class="{ icon ? 'icon' : '' }">{label}</a>
11
+
12
+ <style>
13
+ a {
14
+ text-decoration: underline;
15
+ }
16
+ a.icon {
17
+ background-image: url('/icons/icon-success.svg');
18
+ background-size: 20px auto;
19
+ background-repeat: no-repeat;
20
+ background-position: center;
21
+ padding-left: 28px;
22
+ }
23
+ </style>
24
+
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "iconograph-ui",
3
- "version": "1.3.12",
3
+ "version": "1.3.14",
4
4
  "description": "A Svelte Kit components library",
5
5
  "main": "./index.js",
6
6
  "svelte": "./index.js",