@generation/icons 1.1.2 → 1.1.4

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,46 @@
1
+ import fs from 'fs';
2
+ import path from 'path';
3
+
4
+ const iconsFolder = './src/Icons'; // Carpeta donde están los iconos
5
+ const galleryFilePath = './packages/demo/src/components/Gallery/Gallery.jsx'; // Ruta del archivo Gallery.jsx
6
+
7
+ // Leer el archivo index.js
8
+ const indexPath = path.join(iconsFolder, 'index.js');
9
+ const indexContent = fs.readFileSync(indexPath, 'utf8');
10
+
11
+ // Extraer los nombres de los íconos de los exports en index.js
12
+ const iconNames = Array.from(
13
+ indexContent.matchAll(/export\s+{\s+default\s+as\s+(\w+)\s+}/g),
14
+ (match) => match[1]
15
+ );
16
+
17
+ // Construir el contenido del archivo Gallery.jsx
18
+ const galleryContent = `
19
+ import React from 'react';
20
+ import './styles.css';
21
+ import {
22
+ ${iconNames.join(',\n ')}
23
+ } from '@generation/icons';
24
+
25
+ const Gallery = () => (
26
+ <div className="gallery">
27
+ ${iconNames
28
+ .map(
29
+ (icon) => `
30
+ <div className="gallery-item">
31
+ <div className="gallery-svg">
32
+ <${icon} />
33
+ </div>
34
+ <span>${icon}</span>
35
+ </div>`
36
+ )
37
+ .join('\n ')}
38
+ </div>
39
+ );
40
+
41
+ export default Gallery;
42
+ `;
43
+
44
+ // Crear el archivo Gallery.jsx
45
+ fs.writeFileSync(galleryFilePath, galleryContent, 'utf8');
46
+ console.log(`Gallery.jsx creado en ${galleryFilePath}`);
@@ -1,5 +1,5 @@
1
1
  import * as React from "react";
2
- const Link = (props) => (
2
+ const LinkIcon = (props) => (
3
3
  <svg
4
4
  xmlns="http://www.w3.org/2000/svg"
5
5
  width="1em"
@@ -11,4 +11,4 @@ const Link = (props) => (
11
11
  <path d="M15.31 0h-4v2h4c1.65 0 3 1.35 3 3s-1.35 3-3 3h-4v2h4c2.76 0 5-2.24 5-5s-2.24-5-5-5m-6 8h-4c-1.65 0-3-1.35-3-3s1.35-3 3-3h4V0h-4c-2.76 0-5 2.24-5 5s2.24 5 5 5h4zm-3-4h8v2h-8zm9-4h-4v2h4c1.65 0 3 1.35 3 3s-1.35 3-3 3h-4v2h4c2.76 0 5-2.24 5-5s-2.24-5-5-5m-6 8h-4c-1.65 0-3-1.35-3-3s1.35-3 3-3h4V0h-4c-2.76 0-5 2.24-5 5s2.24 5 5 5h4zm-3-4h8v2h-8z" />
12
12
  </svg>
13
13
  );
14
- export default Link;
14
+ export default LinkIcon;
@@ -0,0 +1,23 @@
1
+ import * as React from "react";
2
+ const NotAvailable = (props) => (
3
+ <svg
4
+ xmlns="http://www.w3.org/2000/svg"
5
+ xmlSpace="preserve"
6
+ viewBox="0 0 24 24"
7
+ width="1em"
8
+ height="1em"
9
+ {...props}
10
+ >
11
+ <path
12
+ d="M0 0h24v24H0z"
13
+ style={{
14
+ fill: "none",
15
+ }}
16
+ />
17
+ <path
18
+ fill="currentColor"
19
+ d="M12 2C6.5 2 2 6.5 2 12s4.5 10 10 10 10-4.5 10-10S17.5 2 12 2m5 11H7v-2h10z"
20
+ />
21
+ </svg>
22
+ );
23
+ export default NotAvailable;
@@ -200,7 +200,7 @@ export { default as JobFill } from './JobFill';
200
200
  export { default as JobFillOut } from './JobFillOut';
201
201
  export { default as LeftArrow } from './LeftArrow';
202
202
  export { default as LeftCaret } from './LeftCaret';
203
- export { default as Link } from './Link';
203
+ export { default as LinkIcon } from './LinkIcon';
204
204
  export { default as Linkedin } from './Linkedin';
205
205
  export { default as List } from './List';
206
206
  export { default as ListOl } from './ListOl';
@@ -231,6 +231,7 @@ export { default as MoreHorizontal } from './MoreHorizontal';
231
231
  export { default as MoreVertical } from './MoreVertical';
232
232
  export { default as Neutral } from './Neutral';
233
233
  export { default as NewTab } from './NewTab';
234
+ export { default as NotAvailable } from './NotAvailable';
234
235
  export { default as NotFeelingGood } from './NotFeelingGood';
235
236
  export { default as NotesFill } from './NotesFill';
236
237
  export { default as NotesFillOut } from './NotesFillOut';
File without changes