@ebrains/react 0.9.0-beta → 0.9.2-beta

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.
Files changed (182) hide show
  1. package/.babelrc +12 -0
  2. package/LICENSE +21 -0
  3. package/README.md +5 -1
  4. package/package.json +2 -6
  5. package/project.json +10 -0
  6. package/rollup.config.js +43 -0
  7. package/src/components.ts +49 -0
  8. package/src/generated/components.ts +47 -0
  9. package/src/generated/react-component-lib/attachProps.ts +125 -0
  10. package/src/generated/react-component-lib/case.ts +7 -0
  11. package/src/generated/react-component-lib/createComponent.tsx +106 -0
  12. package/src/generated/react-component-lib/createOverlayComponent.tsx +142 -0
  13. package/src/generated/react-component-lib/dev.ts +14 -0
  14. package/src/generated/react-component-lib/index.tsx +50 -0
  15. package/src/generated/react-component-lib/interfaces.ts +34 -0
  16. package/src/generated/react-component-lib/utils/attachProps.ts +125 -0
  17. package/src/generated/react-component-lib/utils/case.ts +7 -0
  18. package/src/generated/react-component-lib/utils/dev.ts +14 -0
  19. package/src/generated/react-component-lib/utils/index.tsx +50 -0
  20. package/src/react-component-lib/attachProps.ts +125 -0
  21. package/src/react-component-lib/case.ts +7 -0
  22. package/src/react-component-lib/createComponent.tsx +106 -0
  23. package/src/react-component-lib/createOverlayComponent.tsx +142 -0
  24. package/src/react-component-lib/dev.ts +14 -0
  25. package/src/react-component-lib/index.tsx +50 -0
  26. package/src/react-component-lib/interfaces.ts +34 -0
  27. package/src/react-component-lib/utils/attachProps.ts +125 -0
  28. package/src/react-component-lib/utils/case.ts +7 -0
  29. package/src/react-component-lib/utils/index.tsx +50 -0
  30. package/tsconfig.json +17 -0
  31. package/tsconfig.lib.json +23 -0
  32. package/analytics-44b1416b.esm.js +0 -55
  33. package/arrow-diagonal-black-8f0494c3.esm.js +0 -3
  34. package/arrow-right-9322ba8a.esm.js +0 -5
  35. package/bluesky-cc5edd2d.esm.js +0 -14
  36. package/bookmark-c200037c.esm.js +0 -16
  37. package/chevron-down-6144c823.esm.js +0 -12
  38. package/chevron-left-ca6c66e1.esm.js +0 -11
  39. package/chevron-right-b88ed2d4.esm.js +0 -5
  40. package/chevron-up-c66bd477.esm.js +0 -12
  41. package/close-87fc0d63.esm.js +0 -5
  42. package/color-2554aad6.esm.js +0 -122
  43. package/color-primary-palette_6.entry.esm.js +0 -778
  44. package/components-section.entry.esm.js +0 -165
  45. package/copy-03b72cb6.esm.js +0 -5
  46. package/correct-use-of-colors.entry.esm.js +0 -243
  47. package/docs-palettes.entry.esm.js +0 -29
  48. package/docs-tokens.entry.esm.js +0 -45
  49. package/eds-accordion.entry.esm.js +0 -132
  50. package/eds-alert.entry.esm.js +0 -112
  51. package/eds-app-root.entry.esm.js +0 -53
  52. package/eds-avatar_24.entry.esm.js +0 -275
  53. package/eds-breadcrumb.entry.esm.js +0 -174
  54. package/eds-card-desc_3.entry.esm.js +0 -125
  55. package/eds-card-generic.entry.esm.js +0 -114
  56. package/eds-card-project.entry.esm.js +0 -93
  57. package/eds-card-section.entry.esm.js +0 -56
  58. package/eds-card-tags.entry.esm.js +0 -27
  59. package/eds-card-tool.entry.esm.js +0 -105
  60. package/eds-card-wrapper.entry.esm.js +0 -39
  61. package/eds-code-block.entry.esm.js +0 -2290
  62. package/eds-cookies-preference.entry.esm.js +0 -47
  63. package/eds-feedback.entry.esm.js +0 -82
  64. package/eds-frame.entry.esm.js +0 -112
  65. package/eds-icon-arrow-diagonal.entry.esm.js +0 -21
  66. package/eds-icon-arrow-right.entry.esm.js +0 -21
  67. package/eds-icon-bluesky.entry.esm.js +0 -21
  68. package/eds-icon-bookmark.entry.esm.js +0 -21
  69. package/eds-icon-chevron-down.entry.esm.js +0 -21
  70. package/eds-icon-chevron-left.entry.esm.js +0 -21
  71. package/eds-icon-chevron-right.entry.esm.js +0 -21
  72. package/eds-icon-chevron-up.entry.esm.js +0 -21
  73. package/eds-icon-close.entry.esm.js +0 -21
  74. package/eds-icon-copy.entry.esm.js +0 -21
  75. package/eds-icon-eu.entry.esm.js +0 -21
  76. package/eds-icon-external.entry.esm.js +0 -21
  77. package/eds-icon-facebook.entry.esm.js +0 -21
  78. package/eds-icon-gitlab.entry.esm.js +0 -21
  79. package/eds-icon-linkedin.entry.esm.js +0 -21
  80. package/eds-icon-loader.entry.esm.js +0 -21
  81. package/eds-icon-mastodon.entry.esm.js +0 -21
  82. package/eds-icon-menu.entry.esm.js +0 -21
  83. package/eds-icon-minus.entry.esm.js +0 -21
  84. package/eds-icon-more.entry.esm.js +0 -21
  85. package/eds-icon-paper.entry.esm.js +0 -21
  86. package/eds-icon-plus.entry.esm.js +0 -21
  87. package/eds-icon-portal.entry.esm.js +0 -21
  88. package/eds-icon-private.entry.esm.js +0 -21
  89. package/eds-icon-public.entry.esm.js +0 -21
  90. package/eds-icon-search.entry.esm.js +0 -21
  91. package/eds-icon-star.entry.esm.js +0 -21
  92. package/eds-icon-success.entry.esm.js +0 -21
  93. package/eds-icon-thumbs-down.entry.esm.js +0 -21
  94. package/eds-icon-thumbs-up.entry.esm.js +0 -21
  95. package/eds-icon-tutorial.entry.esm.js +0 -21
  96. package/eds-icon-twitter.entry.esm.js +0 -21
  97. package/eds-icon-unknown.entry.esm.js +0 -21
  98. package/eds-icon-updown.entry.esm.js +0 -21
  99. package/eds-icon-user.entry.esm.js +0 -21
  100. package/eds-icon-youtube.entry.esm.js +0 -21
  101. package/eds-login_2.entry.esm.js +0 -1828
  102. package/eds-matomo-notice.entry.esm.js +0 -162
  103. package/eds-modal.entry.esm.js +0 -142
  104. package/eds-pagination_2.entry.esm.js +0 -493
  105. package/eds-progress-bar.entry.esm.js +0 -41
  106. package/eds-rating.entry.esm.js +0 -79
  107. package/eds-section-core_2.entry.esm.js +0 -69
  108. package/eds-spinner.entry.esm.js +0 -67
  109. package/eds-switch.entry.esm.js +0 -58
  110. package/eds-tabs.entry.esm.js +0 -143
  111. package/eds-timeline.entry.esm.js +0 -117
  112. package/eds-toast-manager.entry.esm.js +0 -62
  113. package/eds-toast.entry.esm.js +0 -92
  114. package/eds-tooltip.entry.esm.js +0 -125
  115. package/eds-trl.entry.esm.js +0 -68
  116. package/eu-9ddde93a.esm.js +0 -30
  117. package/facebook-9cb5c17f.esm.js +0 -14
  118. package/incorrect-use-of-colors.entry.esm.js +0 -71
  119. package/index-39c58238.esm.js +0 -58
  120. package/index.esm.d.ts +0 -1
  121. package/index.esm.js +0 -4
  122. package/index.esm2.js +0 -4840
  123. package/linkedin-e8650abb.esm.js +0 -28
  124. package/loader-c9628637.esm.js +0 -30
  125. package/logo-color-7f1fd803.esm.js +0 -115
  126. package/logo-color-margins-ff8ce71b.esm.js +0 -118
  127. package/logo-space.entry.esm.js +0 -48
  128. package/logo-variations-horizontal_2.entry.esm.js +0 -123
  129. package/logo-variations-tabs.entry.esm.js +0 -29
  130. package/logo-white-no-bg-f382f86f.esm.js +0 -1021
  131. package/logo-wrong-usage.entry.esm.js +0 -101
  132. package/mastodon-3703ec61.esm.js +0 -14
  133. package/menu-340ea948.esm.js +0 -11
  134. package/minus-b30a7c71.esm.js +0 -11
  135. package/mono-53f70232.esm.js +0 -11
  136. package/more-4449d549.esm.js +0 -13
  137. package/paper-8e74ea31.esm.js +0 -15
  138. package/plus-89c07be2.esm.js +0 -12
  139. package/portal-d6c8ce56.esm.js +0 -18
  140. package/private-1c25ff8e.esm.js +0 -25
  141. package/public-d4d8c585.esm.js +0 -16
  142. package/search-fbcd79c2.esm.js +0 -12
  143. package/sharedUtils-a550989c.esm.js +0 -17
  144. package/src/components.d.ts +0 -41
  145. package/src/generated/components.d.ts +0 -38
  146. package/src/generated/react-component-lib/attachProps.d.ts +0 -16
  147. package/src/generated/react-component-lib/case.d.ts +0 -2
  148. package/src/generated/react-component-lib/createComponent.d.ts +0 -10
  149. package/src/generated/react-component-lib/createOverlayComponent.d.ts +0 -21
  150. package/src/generated/react-component-lib/dev.d.ts +0 -2
  151. package/src/generated/react-component-lib/interfaces.d.ts +0 -29
  152. package/src/generated/react-component-lib/utils/attachProps.d.ts +0 -16
  153. package/src/generated/react-component-lib/utils/case.d.ts +0 -2
  154. package/src/generated/react-component-lib/utils/dev.d.ts +0 -2
  155. package/src/generated/react-component-lib/utils/index.d.ts +0 -10
  156. package/src/react-component-lib/attachProps.d.ts +0 -16
  157. package/src/react-component-lib/case.d.ts +0 -2
  158. package/src/react-component-lib/createComponent.d.ts +0 -10
  159. package/src/react-component-lib/createOverlayComponent.d.ts +0 -21
  160. package/src/react-component-lib/dev.d.ts +0 -2
  161. package/src/react-component-lib/interfaces.d.ts +0 -29
  162. package/src/react-component-lib/utils/attachProps.d.ts +0 -16
  163. package/src/react-component-lib/utils/case.d.ts +0 -2
  164. package/src/react-component-lib/utils/index.d.ts +0 -10
  165. package/star-0da9b5e9.esm.js +0 -5
  166. package/success-443809da.esm.js +0 -18
  167. package/svg-repository.entry.esm.js +0 -337
  168. package/thumbs-down-a18fd049.esm.js +0 -5
  169. package/thumbs-up-c19a71bc.esm.js +0 -6
  170. package/toastManager-d9eee791.esm.js +0 -34
  171. package/token-list_3.entry.esm.js +0 -385
  172. package/token-ratios.entry.esm.js +0 -49
  173. package/token-typography.entry.esm.js +0 -267
  174. package/tutotial-150ee1fd.esm.js +0 -27
  175. package/twitter-ac21b505.esm.js +0 -14
  176. package/unknown-ed01a24c.esm.js +0 -22
  177. package/up-and-down-d747abee.esm.js +0 -12
  178. package/user-71ebdc15.esm.js +0 -16
  179. package/youtube-efbfbdc4.esm.js +0 -14
  180. /package/src/generated/react-component-lib/{index.d.ts → index.ts} +0 -0
  181. /package/src/{index.d.ts → index.ts} +0 -0
  182. /package/src/react-component-lib/{index.d.ts → index.ts} +0 -0
@@ -0,0 +1,34 @@
1
+ // General types important to applications using stencil built components
2
+ export interface EventEmitter<T = any> {
3
+ emit: (data?: T) => CustomEvent<T>;
4
+ }
5
+
6
+ export interface StyleReactProps {
7
+ class?: string;
8
+ className?: string;
9
+ style?: { [key: string]: any };
10
+ }
11
+
12
+ export interface OverlayEventDetail<T = any> {
13
+ data?: T;
14
+ role?: string;
15
+ }
16
+
17
+ export interface OverlayInterface {
18
+ el: HTMLElement;
19
+ animated: boolean;
20
+ keyboardClose: boolean;
21
+ overlayIndex: number;
22
+ presented: boolean;
23
+
24
+ enterAnimation?: any;
25
+ leaveAnimation?: any;
26
+
27
+ didPresent: EventEmitter<void>;
28
+ willPresent: EventEmitter<void>;
29
+ willDismiss: EventEmitter<OverlayEventDetail>;
30
+ didDismiss: EventEmitter<OverlayEventDetail>;
31
+
32
+ present(): Promise<void>;
33
+ dismiss(data?: any, role?: string): Promise<boolean>;
34
+ }
@@ -0,0 +1,125 @@
1
+ import { camelToDashCase } from './case';
2
+
3
+ export const attachProps = (node: HTMLElement, newProps: any, oldProps: any = {}) => {
4
+ // some test frameworks don't render DOM elements, so we test here to make sure we are dealing with DOM first
5
+ if (node instanceof Element) {
6
+ // add any classes in className to the class list
7
+ const className = getClassName(node.classList, newProps, oldProps);
8
+ if (className !== '') {
9
+ node.className = className;
10
+ }
11
+
12
+ Object.keys(newProps).forEach((name) => {
13
+ if (
14
+ name === 'children' ||
15
+ name === 'style' ||
16
+ name === 'ref' ||
17
+ name === 'class' ||
18
+ name === 'className' ||
19
+ name === 'forwardedRef'
20
+ ) {
21
+ return;
22
+ }
23
+ if (name.indexOf('on') === 0 && name[2] === name[2].toUpperCase()) {
24
+ const eventName = name.substring(2);
25
+ const eventNameLc = eventName[0].toLowerCase() + eventName.substring(1);
26
+
27
+ if (!isCoveredByReact(eventNameLc)) {
28
+ syncEvent(node, eventNameLc, newProps[name]);
29
+ }
30
+ } else {
31
+ (node as any)[name] = newProps[name];
32
+ const propType = typeof newProps[name];
33
+ if (propType === 'string') {
34
+ node.setAttribute(camelToDashCase(name), newProps[name]);
35
+ }
36
+ }
37
+ });
38
+ }
39
+ };
40
+
41
+ export const getClassName = (classList: DOMTokenList, newProps: any, oldProps: any) => {
42
+ const newClassProp: string = newProps.className || newProps.class;
43
+ const oldClassProp: string = oldProps.className || oldProps.class;
44
+ // map the classes to Maps for performance
45
+ const currentClasses = arrayToMap(classList);
46
+ const incomingPropClasses = arrayToMap(newClassProp ? newClassProp.split(' ') : []);
47
+ const oldPropClasses = arrayToMap(oldClassProp ? oldClassProp.split(' ') : []);
48
+ const finalClassNames: string[] = [];
49
+ // loop through each of the current classes on the component
50
+ // to see if it should be a part of the classNames added
51
+ currentClasses.forEach((currentClass) => {
52
+ if (incomingPropClasses.has(currentClass)) {
53
+ // add it as its already included in classnames coming in from newProps
54
+ finalClassNames.push(currentClass);
55
+ incomingPropClasses.delete(currentClass);
56
+ } else if (!oldPropClasses.has(currentClass)) {
57
+ // add it as it has NOT been removed by user
58
+ finalClassNames.push(currentClass);
59
+ }
60
+ });
61
+ incomingPropClasses.forEach((s) => finalClassNames.push(s));
62
+ return finalClassNames.join(' ');
63
+ };
64
+
65
+ /**
66
+ * Transforms a React event name to a browser event name.
67
+ */
68
+ export const transformReactEventName = (eventNameSuffix: string) => {
69
+ switch (eventNameSuffix) {
70
+ case 'doubleclick':
71
+ return 'dblclick';
72
+ }
73
+ return eventNameSuffix;
74
+ };
75
+
76
+ /**
77
+ * Checks if an event is supported in the current execution environment.
78
+ * @license Modernizr 3.0.0pre (Custom Build) | MIT
79
+ */
80
+ export const isCoveredByReact = (eventNameSuffix: string) => {
81
+ if (typeof document === 'undefined') {
82
+ return true;
83
+ } else {
84
+ const eventName = 'on' + transformReactEventName(eventNameSuffix);
85
+ let isSupported = eventName in document;
86
+
87
+ if (!isSupported) {
88
+ const element = document.createElement('div');
89
+ element.setAttribute(eventName, 'return;');
90
+ isSupported = typeof (element as any)[eventName] === 'function';
91
+ }
92
+
93
+ return isSupported;
94
+ }
95
+ };
96
+
97
+ export const syncEvent = (
98
+ node: Element & { __events?: { [key: string]: ((e: Event) => any) | undefined } },
99
+ eventName: string,
100
+ newEventHandler?: (e: Event) => any
101
+ ) => {
102
+ const eventStore = node.__events || (node.__events = {});
103
+ const oldEventHandler = eventStore[eventName];
104
+
105
+ // Remove old listener so they don't double up.
106
+ if (oldEventHandler) {
107
+ node.removeEventListener(eventName, oldEventHandler);
108
+ }
109
+
110
+ // Bind new listener.
111
+ node.addEventListener(
112
+ eventName,
113
+ (eventStore[eventName] = function handler(e: Event) {
114
+ if (newEventHandler) {
115
+ newEventHandler.call(this, e);
116
+ }
117
+ })
118
+ );
119
+ };
120
+
121
+ const arrayToMap = (arr: string[] | DOMTokenList) => {
122
+ const map = new Map<string, string>();
123
+ (arr as string[]).forEach((s: string) => map.set(s, s));
124
+ return map;
125
+ };
@@ -0,0 +1,7 @@
1
+ export const dashToPascalCase = (str: string) =>
2
+ str
3
+ .toLowerCase()
4
+ .split('-')
5
+ .map((segment) => segment.charAt(0).toUpperCase() + segment.slice(1))
6
+ .join('');
7
+ export const camelToDashCase = (str: string) => str.replace(/([A-Z])/g, (m: string) => `-${m[0].toLowerCase()}`);
@@ -0,0 +1,50 @@
1
+ import React from 'react';
2
+
3
+ import type { StyleReactProps } from '../interfaces';
4
+
5
+ export type StencilReactExternalProps<PropType, ElementType> = PropType &
6
+ Omit<React.HTMLAttributes<ElementType>, 'style'> &
7
+ StyleReactProps;
8
+
9
+ // This will be replaced with React.ForwardedRef when react-output-target is upgraded to React v17
10
+ export type StencilReactForwardedRef<T> = ((instance: T | null) => void) | React.MutableRefObject<T | null> | null;
11
+
12
+ export const setRef = (ref: StencilReactForwardedRef<any> | React.Ref<any> | undefined, value: any) => {
13
+ if (typeof ref === 'function') {
14
+ ref(value);
15
+ } else if (ref != null) {
16
+ // Cast as a MutableRef so we can assign current
17
+ (ref as React.MutableRefObject<any>).current = value;
18
+ }
19
+ };
20
+
21
+ export const mergeRefs = (
22
+ ...refs: (StencilReactForwardedRef<any> | React.Ref<any> | undefined)[]
23
+ ): React.RefCallback<any> => {
24
+ return (value: any) => {
25
+ refs.forEach((ref) => {
26
+ setRef(ref, value);
27
+ });
28
+ };
29
+ };
30
+
31
+ export const createForwardRef = <PropType, ElementType>(ReactComponent: any, displayName: string) => {
32
+ const forwardRef = (
33
+ props: StencilReactExternalProps<PropType, ElementType>,
34
+ ref: StencilReactForwardedRef<ElementType>
35
+ ) => {
36
+ return <ReactComponent {...props} forwardedRef={ref} />;
37
+ };
38
+ forwardRef.displayName = displayName;
39
+
40
+ return React.forwardRef(forwardRef);
41
+ };
42
+
43
+ export const defineCustomElement = (tagName: string, customElement: any) => {
44
+ if (customElement !== undefined && typeof customElements !== 'undefined' && !customElements.get(tagName)) {
45
+ customElements.define(tagName, customElement);
46
+ }
47
+ };
48
+
49
+ export * from './attachProps';
50
+ export * from './case';
package/tsconfig.json ADDED
@@ -0,0 +1,17 @@
1
+ {
2
+ "compilerOptions": {
3
+ "jsx": "react-jsx",
4
+ "allowJs": false,
5
+ "esModuleInterop": false,
6
+ "allowSyntheticDefaultImports": true,
7
+ "strict": true
8
+ },
9
+ "files": [],
10
+ "include": [],
11
+ "references": [
12
+ {
13
+ "path": "./tsconfig.lib.json"
14
+ }
15
+ ],
16
+ "extends": "../../tsconfig.base.json"
17
+ }
@@ -0,0 +1,23 @@
1
+ {
2
+ "extends": "./tsconfig.json",
3
+ "compilerOptions": {
4
+ "outDir": "../../dist/out-tsc",
5
+ "types": [
6
+ "node",
7
+ "@nx/react/typings/cssmodule.d.ts",
8
+ "@nx/react/typings/image.d.ts"
9
+ ]
10
+ },
11
+ "exclude": [
12
+ "jest.config.ts",
13
+ "src/**/*.spec.ts",
14
+ "src/**/*.test.ts",
15
+ "src/**/*.spec.tsx",
16
+ "src/**/*.test.tsx",
17
+ "src/**/*.spec.js",
18
+ "src/**/*.test.js",
19
+ "src/**/*.spec.jsx",
20
+ "src/**/*.test.jsx"
21
+ ],
22
+ "include": ["src/**/*.js", "src/**/*.jsx", "src/**/*.ts", "src/**/*.tsx"]
23
+ }
@@ -1,55 +0,0 @@
1
- // Helper function to check if Matomo is initialized
2
- function isMatomoAvailable() {
3
- return typeof window !== 'undefined' && typeof window._paq !== 'undefined';
4
- }
5
- // General function to push data to Matomo
6
- function pushToMatomo(action, ...args) {
7
- //console.log('Pushing Matomo')
8
- if (isMatomoAvailable()) {
9
- window._paq.push([action, ...args]);
10
- } else {
11
- // eslint-disable-next-line
12
- console.warn('Matomo is not available or not initialized.');
13
- }
14
- }
15
- // Function to send analytics data
16
- function sendAnalytics(eventData) {
17
- var _a;
18
- if (!isMatomoAvailable()) {
19
- // eslint-disable-next-line
20
- console.warn('Matomo is not available or not initialized.');
21
- // eslint-disable-next-line
22
- console.log(Object.assign({}, eventData));
23
- return;
24
- }
25
- // Conditionally build the name field
26
- const nameParts = [];
27
- if ((_a = eventData.parentContext) === null || _a === void 0 ? void 0 : _a.componentName) {
28
- nameParts.push(eventData.parentContext.componentName);
29
- }
30
- nameParts.push(eventData.tag || 'unknown-tag');
31
- nameParts.push(eventData.name || 'unknown-name');
32
- const name = nameParts.join('/');
33
- //console.log('trackEvent', eventData.category, eventData.action, name)
34
- pushToMatomo('trackEvent', eventData.category, eventData.action, name);
35
- // eslint-disable-next-line
36
- console.log(Object.assign({}, eventData));
37
- }
38
- // Function to opt-in the user
39
- function matomoOptIn() {
40
- if (isMatomoAvailable()) {
41
- window._paq.push(['rememberConsentGiven']);
42
- // eslint-disable-next-line
43
- console.log('User has opted in to tracking');
44
- }
45
- }
46
- // Function to opt-out the user
47
- function matomoOptOut() {
48
- if (isMatomoAvailable()) {
49
- window._paq.push(['forgetConsentGiven']);
50
- // eslint-disable-next-line
51
- console.log('User has opted out of tracking');
52
- }
53
- }
54
-
55
- export { matomoOptOut as a, matomoOptIn as m, sendAnalytics as s };
@@ -1,3 +0,0 @@
1
- const arrowDiagonal = `<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M10.5858 3H17V9.41421L14.5 6.91421L8.70712 12.7071L7.29291 11.2929L13.0858 5.5L10.5858 3Z" fill="currentColor"></path><path d="M8 4H5C3.89543 4 3 4.89543 3 6V15C3 16.1046 3.89543 17 5 17H14C15.1046 17 16 16.1046 16 15V12H14V15H5V6H8V4Z" fill="currentColor"></path></svg>`;
2
-
3
- export { arrowDiagonal as a };
@@ -1,5 +0,0 @@
1
- const arrowRight = `<svg width="20" height="20" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 20 20">
2
- <path fill="currentColor" d="M2 8.5h9V3l7 7-7 7v-5.5H2v-3Z" />
3
- </svg>`;
4
-
5
- export { arrowRight as a };
@@ -1,14 +0,0 @@
1
- const bluesky = ` <svg
2
- width="24"
3
- height="24"
4
- viewBox="0 0 24 24"
5
- fill="none"
6
- xmlns="http://www.w3.org/2000/svg"
7
- >
8
- <path
9
- d="M12 10.8728C10.9812 8.89138 8.20675 5.19886 5.62717 3.37775C3.15607 1.63323 2.21338 1.9355 1.59538 2.21475C0.880058 2.53797 0.75 3.63616 0.75 4.28228C0.75 4.92839 1.10422 9.5795 1.33526 10.3559C2.09866 12.9211 4.81627 13.7879 7.319 13.5098C7.44694 13.4908 7.57669 13.4733 7.70807 13.457C7.57919 13.4776 7.44938 13.4953 7.319 13.5098C3.65128 14.0529 0.393987 15.3896 4.66614 20.1456C9.3655 25.0113 11.1066 19.1023 12 16.1064C12.8934 19.1023 13.9225 24.7982 19.2497 20.1456C23.25 16.1064 20.3488 14.0531 16.681 13.5099C16.5506 13.4954 16.4208 13.4778 16.2919 13.4572C16.4233 13.4734 16.5531 13.4909 16.681 13.5099C19.1838 13.7881 21.9013 12.9213 22.6648 10.3561C22.8958 9.57969 23.25 4.92855 23.25 4.28244C23.25 3.63632 23.1199 2.53813 22.4046 2.21491C21.7866 1.93566 20.8439 1.63339 18.3728 3.37791C15.7933 5.19902 13.0188 8.89138 12 10.8728Z"
10
- fill="currentColor"
11
- />
12
- </svg>`;
13
-
14
- export { bluesky as b };
@@ -1,16 +0,0 @@
1
- const bookmark = ` <svg
2
- width="20"
3
- height="20"
4
- viewBox="0 0 20 20"
5
- fill="none"
6
- xmlns="http://www.w3.org/2000/svg"
7
- >
8
- <path
9
- d="M5 4H15V16L10 12.0138L5 16V4Z"
10
- stroke="currentColor"
11
- stroke-width="1.5"
12
- stroke-linejoin="round"
13
- />
14
- </svg>`;
15
-
16
- export { bookmark as b };
@@ -1,12 +0,0 @@
1
- const chevronDown = `<svg
2
- width="20"
3
- height="20"
4
- viewBox="0 0 20 20"
5
- fill="none"
6
- xmlns="http://www.w3.org/2000/svg"
7
- >
8
- <path d="M10 13L4 7H16L10 13Z" fill="currentColor" />
9
- </svg>
10
- `;
11
-
12
- export { chevronDown as c };
@@ -1,11 +0,0 @@
1
- const chevronLeft = ` <svg
2
- width="20"
3
- height="20"
4
- viewBox="0 0 20 20"
5
- fill="none"
6
- xmlns="http://www.w3.org/2000/svg"
7
- >
8
- <path d="M7 10L13 4L13 16L7 10Z" fill="currentColor" />
9
- </svg>`;
10
-
11
- export { chevronLeft as c };
@@ -1,5 +0,0 @@
1
- const chevronRight = ` <svg width="20" height="20" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 20 20">
2
- <path fill="currentColor" d="m13 10-6 6V4l6 6Z" />
3
- </svg>`;
4
-
5
- export { chevronRight as c };
@@ -1,12 +0,0 @@
1
- const chevronUp = `<svg
2
- width="20"
3
- height="20"
4
- viewBox="0 0 20 20"
5
- fill="none"
6
- xmlns="http://www.w3.org/2000/svg"
7
- >
8
- <path d="M4 13L10 7L16 13L4 13Z" fill="currentColor" />
9
- </svg>
10
- `;
11
-
12
- export { chevronUp as c };
@@ -1,5 +0,0 @@
1
- const close = `<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="none" viewBox="0 0 20 20">
2
- <path stroke="currentColor" stroke-width="2" d="M16 4 4 16m12 0L4 4" />
3
- </svg>`;
4
-
5
- export { close as c };
@@ -1,122 +0,0 @@
1
- import { c as cva } from './index-39c58238.esm.js';
2
-
3
- const GRADIANT_TOKENS = ['green', 'yellow', 'among-blue', 'purple'];
4
- const gradientBGColorVariants = cva([], {
5
- variants: {
6
- color: GRADIANT_TOKENS.reduce((acc, token) => Object.assign(Object.assign({}, acc), {
7
- [token]: ''
8
- }), {}),
9
- direction: {
10
- top: '',
11
- bottom: ''
12
- },
13
- pseudo: {
14
- true: 'before:effect-opacity effect-bg-behind',
15
- false: ''
16
- },
17
- hover: {
18
- true: 'before:opacity-0 hover:before:opacity-100',
19
- false: ''
20
- }
21
- },
22
- compoundVariants: [
23
- // region GREEN
24
- {
25
- color: 'green',
26
- direction: 'top',
27
- pseudo: true,
28
- className: 'before:bg-gradient-01-top'
29
- }, {
30
- color: 'green',
31
- pseudo: true,
32
- direction: 'bottom',
33
- className: 'before:bg-gradient-01-bottom'
34
- }, {
35
- color: 'green',
36
- direction: 'top',
37
- pseudo: false,
38
- className: 'bg-gradient-01-top'
39
- }, {
40
- color: 'green',
41
- pseudo: false,
42
- direction: 'bottom',
43
- className: 'bg-gradient-01-bottom'
44
- },
45
- // endregion
46
- // region YELLOW
47
- {
48
- color: 'yellow',
49
- direction: 'top',
50
- pseudo: true,
51
- className: 'before:bg-gradient-02-top'
52
- }, {
53
- color: 'yellow',
54
- direction: 'bottom',
55
- pseudo: true,
56
- className: 'before:bg-gradient-02-bottom'
57
- }, {
58
- color: 'yellow',
59
- direction: 'top',
60
- pseudo: false,
61
- className: 'bg-gradient-02-top'
62
- }, {
63
- color: 'yellow',
64
- direction: 'bottom',
65
- pseudo: false,
66
- className: 'bg-gradient-02-bottom'
67
- },
68
- // endregion
69
- // region PURPLE
70
- {
71
- color: 'purple',
72
- direction: 'top',
73
- pseudo: true,
74
- class: 'before:bg-gradient-03-top'
75
- }, {
76
- color: 'purple',
77
- direction: 'bottom',
78
- pseudo: true,
79
- class: 'before:bg-gradient-03-bottom'
80
- }, {
81
- color: 'purple',
82
- direction: 'top',
83
- pseudo: false,
84
- class: 'bg-gradient-03-top'
85
- }, {
86
- color: 'purple',
87
- direction: 'bottom',
88
- pseudo: false,
89
- class: 'bg-gradient-03-bottom'
90
- },
91
- // endregion
92
- // region AMONG-BLUE
93
- {
94
- color: 'among-blue',
95
- direction: 'top',
96
- pseudo: true,
97
- class: 'before:bg-gradient-04-top'
98
- }, {
99
- color: 'among-blue',
100
- direction: 'bottom',
101
- pseudo: true,
102
- class: 'before:bg-gradient-04-bottom'
103
- }, {
104
- color: 'among-blue',
105
- direction: 'top',
106
- pseudo: false,
107
- class: 'bg-gradient-04-top'
108
- }, {
109
- color: 'among-blue',
110
- direction: 'bottom',
111
- pseudo: false,
112
- class: 'bg-gradient-04-bottom'
113
- }
114
- // endregion
115
- ],
116
- defaultVariants: {
117
- direction: 'top',
118
- pseudo: true
119
- }
120
- });
121
-
122
- export { gradientBGColorVariants as g };