@universal-tennis/ui-shared 0.1.38 → 0.1.39
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/stories/atoms/Icons/CalendarIcon.d.ts +3 -0
- package/dist/stories/atoms/Icons/CalendarIcon.js +8 -0
- package/dist/stories/atoms/Icons/CalendarIcon.js.map +1 -0
- package/dist/stories/atoms/Icons/Icons.stories.d.ts +6 -0
- package/dist/stories/atoms/Icons/Icons.stories.js +26 -0
- package/dist/stories/atoms/Icons/Icons.stories.js.map +1 -0
- package/dist/stories/atoms/Icons/SessionIcon.d.ts +3 -0
- package/dist/stories/atoms/Icons/SessionIcon.js +7 -0
- package/dist/stories/atoms/Icons/SessionIcon.js.map +1 -0
- package/dist/stories/atoms/Icons/sharedTypes.d.ts +4 -0
- package/dist/stories/atoms/Icons/sharedTypes.js +2 -0
- package/dist/stories/atoms/Icons/sharedTypes.js.map +1 -0
- package/package.json +1 -1
- package/src/stories/assets/icons/icon-calendar.svg +4 -0
- package/src/stories/assets/icons/icon-session.svg +3 -0
- package/src/stories/atoms/Icons/CalendarIcon.tsx +12 -0
- package/src/stories/atoms/Icons/Icons.stories.tsx +32 -0
- package/src/stories/atoms/Icons/SessionIcon.tsx +16 -0
- package/src/stories/atoms/Icons/sharedTypes.tsx +4 -0
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/* eslint-disable max-len */
|
|
2
|
+
import React from 'react';
|
|
3
|
+
export default function CalendarIcon({ size, color }) {
|
|
4
|
+
return (React.createElement("svg", { width: size, height: size, viewBox: "0 0 14 14", fill: color, xmlns: "http://www.w3.org/2000/svg" },
|
|
5
|
+
React.createElement("rect", { width: "14", height: "14", fill: "none" }),
|
|
6
|
+
React.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M4.5 0.5C4.77614 0.5 5 0.723858 5 1V2H9V1C9 0.723858 9.22386 0.5 9.5 0.5C9.77614 0.5 10 0.723858 10 1V2H11C12.1046 2 13 2.89543 13 4V11C13 12.1046 12.1046 13 11 13H3C1.89543 13 1 12.1046 1 11V4C1 2.89543 1.89543 2 3 2H4V1C4 0.723858 4.22386 0.5 4.5 0.5ZM9 3V4C9 4.27614 9.22386 4.5 9.5 4.5C9.77614 4.5 10 4.27614 10 4V3H11C11.5523 3 12 3.44772 12 4V6.08325H2V4C2 3.44772 2.44772 3 3 3H4V4C4 4.27614 4.22386 4.5 4.5 4.5C4.77614 4.5 5 4.27614 5 4V3H9ZM2 7.08325V11C2 11.5523 2.44772 12 3 12H11C11.5523 12 12 11.5523 12 11V7.08325H2Z" })));
|
|
7
|
+
}
|
|
8
|
+
//# sourceMappingURL=CalendarIcon.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CalendarIcon.js","sourceRoot":"","sources":["../../../../src/stories/atoms/Icons/CalendarIcon.tsx"],"names":[],"mappings":"AAAA,4BAA4B;AAC5B,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,MAAM,CAAC,OAAO,UAAU,YAAY,CAAC,EAAE,IAAI,EAAE,KAAK,EAAa;IAC7D,OAAO,CACH,6BAAK,KAAK,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,EAAC,WAAW,EAAC,IAAI,EAAE,KAAK,EAAE,KAAK,EAAC,4BAA4B;QAC/F,8BAAM,KAAK,EAAC,IAAI,EAAC,MAAM,EAAC,IAAI,EAAC,IAAI,EAAC,MAAM,GAAG;QAC3C,8BAAM,QAAQ,EAAC,SAAS,EAAC,QAAQ,EAAC,SAAS,EAAC,CAAC,EAAC,ohBAAohB,GAAG,CACnkB,CACT,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import CalendarIcon from './CalendarIcon';
|
|
3
|
+
import SessionIcon from './SessionIcon';
|
|
4
|
+
// Default
|
|
5
|
+
export default {
|
|
6
|
+
title: 'Atoms/Icons',
|
|
7
|
+
};
|
|
8
|
+
// Templates
|
|
9
|
+
function CalendarIconTemplate(args) {
|
|
10
|
+
return React.createElement(CalendarIcon, Object.assign({}, args));
|
|
11
|
+
}
|
|
12
|
+
function SessionIconTemplate(args) {
|
|
13
|
+
return React.createElement(SessionIcon, Object.assign({}, args));
|
|
14
|
+
}
|
|
15
|
+
// Stories
|
|
16
|
+
export const Calendar = CalendarIconTemplate.bind({});
|
|
17
|
+
Calendar.args = {
|
|
18
|
+
size: 50,
|
|
19
|
+
color: 'green'
|
|
20
|
+
};
|
|
21
|
+
export const Session = SessionIconTemplate.bind({});
|
|
22
|
+
Session.args = {
|
|
23
|
+
size: 50,
|
|
24
|
+
color: 'red'
|
|
25
|
+
};
|
|
26
|
+
//# sourceMappingURL=Icons.stories.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Icons.stories.js","sourceRoot":"","sources":["../../../../src/stories/atoms/Icons/Icons.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,YAAY,MAAM,gBAAgB,CAAC;AAC1C,OAAO,WAAW,MAAM,eAAe,CAAC;AAGxC,UAAU;AACV,eAAe;IACb,KAAK,EAAE,aAAa;CACrB,CAAC;AAEF,YAAY;AACZ,SAAS,oBAAoB,CAAC,IAAe;IAC3C,OAAO,oBAAC,YAAY,oBAAK,IAAI,EAAI,CAAC;AACpC,CAAC;AAED,SAAS,mBAAmB,CAAC,IAAe;IAC1C,OAAO,oBAAC,WAAW,oBAAK,IAAI,EAAI,CAAC;AACnC,CAAC;AAED,UAAU;AACV,MAAM,CAAC,MAAM,QAAQ,GAAG,oBAAoB,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AACtD,QAAQ,CAAC,IAAI,GAAG;IACd,IAAI,EAAE,EAAE;IACR,KAAK,EAAE,OAAO;CACf,CAAC;AAEF,MAAM,CAAC,MAAM,OAAO,GAAG,mBAAmB,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AACpD,OAAO,CAAC,IAAI,GAAG;IACb,IAAI,EAAE,EAAE;IACR,KAAK,EAAE,KAAK;CACb,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/* eslint-disable max-len */
|
|
2
|
+
import React from 'react';
|
|
3
|
+
export default function SessionIcon({ size, color }) {
|
|
4
|
+
return (React.createElement("svg", { width: size, height: size, viewBox: "0 0 14 14", fill: color, xmlns: "http://www.w3.org/2000/svg" },
|
|
5
|
+
React.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M3 1H11C11.5523 1 12 1.44772 12 2V12C12 12.5523 11.5523 13 11 13H3C2.44772 13 2 12.5523 2 12V2C2 1.44772 2.44772 1 3 1ZM1 2C1 0.89543 1.89543 0 3 0H11C12.1046 0 13 0.895431 13 2V12C13 13.1046 12.1046 14 11 14H3C1.89543 14 1 13.1046 1 12V2ZM4.5 3C4.22386 3 4 3.22386 4 3.5C4 3.77614 4.22386 4 4.5 4H9.5C9.77614 4 10 3.77614 10 3.5C10 3.22386 9.77614 3 9.5 3H4.5ZM4 6.5C4 6.22386 4.22386 6 4.5 6H9.5C9.77614 6 10 6.22386 10 6.5C10 6.77614 9.77614 7 9.5 7H4.5C4.22386 7 4 6.77614 4 6.5ZM4.5 9C4.22386 9 4 9.22386 4 9.5C4 9.77614 4.22386 10 4.5 10H7.5C7.77614 10 8 9.77614 8 9.5C8 9.22386 7.77614 9 7.5 9H4.5Z" })));
|
|
6
|
+
}
|
|
7
|
+
//# sourceMappingURL=SessionIcon.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SessionIcon.js","sourceRoot":"","sources":["../../../../src/stories/atoms/Icons/SessionIcon.tsx"],"names":[],"mappings":"AAAA,4BAA4B;AAC5B,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,EAAE,IAAI,EAAE,KAAK,EAAa;IAC5D,OAAO,CACH,6BAAK,KAAK,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,EAAC,WAAW,EAAC,IAAI,EAAE,KAAK,EAAE,KAAK,EAAC,4BAA4B;QAC/F,8BACI,QAAQ,EAAC,SAAS,EAClB,QAAQ,EAAC,SAAS,EAClB,CAAC,EAAC,+lBAA+lB,GACnmB,CACA,CACT,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sharedTypes.js","sourceRoot":"","sources":["../../../../src/stories/atoms/Icons/sharedTypes.tsx"],"names":[],"mappings":""}
|
package/package.json
CHANGED
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
<svg width="14" height="14" viewBox="0 0 14 14" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<rect width="14" height="14" fill="#1E1E1E"/>
|
|
3
|
+
<path fill-rule="evenodd" clip-rule="evenodd" d="M4.5 0.5C4.77614 0.5 5 0.723858 5 1V2H9V1C9 0.723858 9.22386 0.5 9.5 0.5C9.77614 0.5 10 0.723858 10 1V2H11C12.1046 2 13 2.89543 13 4V11C13 12.1046 12.1046 13 11 13H3C1.89543 13 1 12.1046 1 11V4C1 2.89543 1.89543 2 3 2H4V1C4 0.723858 4.22386 0.5 4.5 0.5ZM9 3V4C9 4.27614 9.22386 4.5 9.5 4.5C9.77614 4.5 10 4.27614 10 4V3H11C11.5523 3 12 3.44772 12 4V6.08325H2V4C2 3.44772 2.44772 3 3 3H4V4C4 4.27614 4.22386 4.5 4.5 4.5C4.77614 4.5 5 4.27614 5 4V3H9ZM2 7.08325V11C2 11.5523 2.44772 12 3 12H11C11.5523 12 12 11.5523 12 11V7.08325H2Z" fill="black"/>
|
|
4
|
+
</svg>
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
<svg width="14" height="14" viewBox="0 0 14 14" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path fill-rule="evenodd" clip-rule="evenodd" d="M3 1H11C11.5523 1 12 1.44772 12 2V12C12 12.5523 11.5523 13 11 13H3C2.44772 13 2 12.5523 2 12V2C2 1.44772 2.44772 1 3 1ZM1 2C1 0.89543 1.89543 0 3 0H11C12.1046 0 13 0.895431 13 2V12C13 13.1046 12.1046 14 11 14H3C1.89543 14 1 13.1046 1 12V2ZM4.5 3C4.22386 3 4 3.22386 4 3.5C4 3.77614 4.22386 4 4.5 4H9.5C9.77614 4 10 3.77614 10 3.5C10 3.22386 9.77614 3 9.5 3H4.5ZM4 6.5C4 6.22386 4.22386 6 4.5 6H9.5C9.77614 6 10 6.22386 10 6.5C10 6.77614 9.77614 7 9.5 7H4.5C4.22386 7 4 6.77614 4 6.5ZM4.5 9C4.22386 9 4 9.22386 4 9.5C4 9.77614 4.22386 10 4.5 10H7.5C7.77614 10 8 9.77614 8 9.5C8 9.22386 7.77614 9 7.5 9H4.5Z" fill="black"/>
|
|
3
|
+
</svg>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/* eslint-disable max-len */
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { IconProps } from './sharedTypes';
|
|
4
|
+
|
|
5
|
+
export default function CalendarIcon({ size, color }: IconProps) {
|
|
6
|
+
return (
|
|
7
|
+
<svg width={size} height={size} viewBox="0 0 14 14" fill={color} xmlns="http://www.w3.org/2000/svg">
|
|
8
|
+
<rect width="14" height="14" fill="none" />
|
|
9
|
+
<path fillRule="evenodd" clipRule="evenodd" d="M4.5 0.5C4.77614 0.5 5 0.723858 5 1V2H9V1C9 0.723858 9.22386 0.5 9.5 0.5C9.77614 0.5 10 0.723858 10 1V2H11C12.1046 2 13 2.89543 13 4V11C13 12.1046 12.1046 13 11 13H3C1.89543 13 1 12.1046 1 11V4C1 2.89543 1.89543 2 3 2H4V1C4 0.723858 4.22386 0.5 4.5 0.5ZM9 3V4C9 4.27614 9.22386 4.5 9.5 4.5C9.77614 4.5 10 4.27614 10 4V3H11C11.5523 3 12 3.44772 12 4V6.08325H2V4C2 3.44772 2.44772 3 3 3H4V4C4 4.27614 4.22386 4.5 4.5 4.5C4.77614 4.5 5 4.27614 5 4V3H9ZM2 7.08325V11C2 11.5523 2.44772 12 3 12H11C11.5523 12 12 11.5523 12 11V7.08325H2Z" />
|
|
10
|
+
</svg>
|
|
11
|
+
);
|
|
12
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
|
|
3
|
+
import CalendarIcon from './CalendarIcon';
|
|
4
|
+
import SessionIcon from './SessionIcon';
|
|
5
|
+
import { IconProps } from './sharedTypes';
|
|
6
|
+
|
|
7
|
+
// Default
|
|
8
|
+
export default {
|
|
9
|
+
title: 'Atoms/Icons',
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
// Templates
|
|
13
|
+
function CalendarIconTemplate(args: IconProps) {
|
|
14
|
+
return <CalendarIcon {...args} />;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
function SessionIconTemplate(args: IconProps) {
|
|
18
|
+
return <SessionIcon {...args} />;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
// Stories
|
|
22
|
+
export const Calendar = CalendarIconTemplate.bind({});
|
|
23
|
+
Calendar.args = {
|
|
24
|
+
size: 50,
|
|
25
|
+
color: 'green'
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
export const Session = SessionIconTemplate.bind({});
|
|
29
|
+
Session.args = {
|
|
30
|
+
size: 50,
|
|
31
|
+
color: 'red'
|
|
32
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/* eslint-disable max-len */
|
|
2
|
+
import React from 'react';
|
|
3
|
+
|
|
4
|
+
import { IconProps } from './sharedTypes';
|
|
5
|
+
|
|
6
|
+
export default function SessionIcon({ size, color }: IconProps) {
|
|
7
|
+
return (
|
|
8
|
+
<svg width={size} height={size} viewBox="0 0 14 14" fill={color} xmlns="http://www.w3.org/2000/svg">
|
|
9
|
+
<path
|
|
10
|
+
fillRule="evenodd"
|
|
11
|
+
clipRule="evenodd"
|
|
12
|
+
d="M3 1H11C11.5523 1 12 1.44772 12 2V12C12 12.5523 11.5523 13 11 13H3C2.44772 13 2 12.5523 2 12V2C2 1.44772 2.44772 1 3 1ZM1 2C1 0.89543 1.89543 0 3 0H11C12.1046 0 13 0.895431 13 2V12C13 13.1046 12.1046 14 11 14H3C1.89543 14 1 13.1046 1 12V2ZM4.5 3C4.22386 3 4 3.22386 4 3.5C4 3.77614 4.22386 4 4.5 4H9.5C9.77614 4 10 3.77614 10 3.5C10 3.22386 9.77614 3 9.5 3H4.5ZM4 6.5C4 6.22386 4.22386 6 4.5 6H9.5C9.77614 6 10 6.22386 10 6.5C10 6.77614 9.77614 7 9.5 7H4.5C4.22386 7 4 6.77614 4 6.5ZM4.5 9C4.22386 9 4 9.22386 4 9.5C4 9.77614 4.22386 10 4.5 10H7.5C7.77614 10 8 9.77614 8 9.5C8 9.22386 7.77614 9 7.5 9H4.5Z"
|
|
13
|
+
/>
|
|
14
|
+
</svg>
|
|
15
|
+
);
|
|
16
|
+
}
|