@ebrains/react 1.0.0 → 1.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/components-section.entry.esm.js +1 -1
- package/eds-accordion.entry.esm.js +9 -9
- package/eds-alert.entry.esm.js +2 -2
- package/{eds-avatar_34.entry.esm.js → eds-avatar_28.entry.esm.js} +694 -775
- package/eds-breadcrumb.entry.esm.js +179 -0
- package/eds-card-desc_2.entry.esm.js +85 -0
- package/eds-card-generic.entry.esm.js +114 -0
- package/eds-card-project.entry.esm.js +10 -10
- package/eds-card-tags.entry.esm.js +1 -1
- package/eds-card-tool.entry.esm.js +4 -4
- package/eds-code-block.entry.esm.js +7 -7
- package/eds-gauge.entry.esm.js +78 -0
- package/eds-icon-arrow-diagonal.entry.esm.js +1 -1
- package/eds-icon-arrow-right.entry.esm.js +1 -1
- package/eds-icon-bluesky.entry.esm.js +1 -1
- package/eds-icon-bookmark.entry.esm.js +1 -1
- package/eds-icon-chevron-down.entry.esm.js +1 -1
- package/eds-icon-chevron-left.entry.esm.js +1 -1
- package/eds-icon-chevron-right.entry.esm.js +1 -1
- package/eds-icon-chevron-up.entry.esm.js +1 -1
- package/eds-icon-close.entry.esm.js +1 -1
- package/eds-icon-copy.entry.esm.js +1 -1
- package/eds-icon-eu.entry.esm.js +1 -1
- package/eds-icon-external.entry.esm.js +1 -1
- package/eds-icon-facebook.entry.esm.js +1 -1
- package/eds-icon-gitlab.entry.esm.js +1 -1
- package/eds-icon-linkedin.entry.esm.js +1 -1
- package/eds-icon-loader.entry.esm.js +1 -1
- package/eds-icon-mastodon.entry.esm.js +1 -1
- package/eds-icon-menu.entry.esm.js +1 -1
- package/eds-icon-minus.entry.esm.js +1 -1
- package/eds-icon-more.entry.esm.js +1 -1
- package/eds-icon-paper.entry.esm.js +1 -1
- package/eds-icon-plus.entry.esm.js +1 -1
- package/eds-icon-portal.entry.esm.js +1 -1
- package/eds-icon-private.entry.esm.js +1 -1
- package/eds-icon-public.entry.esm.js +1 -1
- package/eds-icon-search.entry.esm.js +1 -1
- package/eds-icon-star.entry.esm.js +1 -1
- package/eds-icon-success.entry.esm.js +1 -1
- package/eds-icon-thumbs-down.entry.esm.js +1 -1
- package/eds-icon-thumbs-up.entry.esm.js +1 -1
- package/eds-icon-tutorial.entry.esm.js +1 -1
- package/eds-icon-twitter.entry.esm.js +1 -1
- package/eds-icon-unknown.entry.esm.js +1 -1
- package/eds-icon-updown.entry.esm.js +1 -1
- package/eds-icon-user.entry.esm.js +1 -1
- package/eds-icon-youtube.entry.esm.js +1 -1
- package/eds-pie.entry.esm.js +131 -0
- package/eds-progress-bar.entry.esm.js +4 -4
- package/eds-rating.entry.esm.js +1 -1
- package/eds-section-core_2.entry.esm.js +5 -5
- package/eds-spinner.entry.esm.js +3 -3
- package/eds-switch.entry.esm.js +5 -5
- package/eds-tooltip.entry.esm.js +41 -0
- package/index.esm2.js +23 -5
- package/package.json +1 -1
- package/token-spacing.entry.esm.js +93 -0
- package/eds-pagination_2.entry.esm.js +0 -493
|
@@ -85,7 +85,7 @@ const DocsReact = () => h("div", null, h("h2", null, "React Wrappers"), h("p", n
|
|
|
85
85
|
"section-title": "Example React App",
|
|
86
86
|
"heading-level": "h3"
|
|
87
87
|
}, h("p", null, "This code displays a Stencil-based splash screen that stays visible until an initialization promise resolves (or errors), then hides itself and reveals the main React app content."), h("eds-code-block", {
|
|
88
|
-
code: "\nimport React, { useMemo, useState } from 'react';\nimport {\n EdsHeader
|
|
88
|
+
code: "\nimport React, { useMemo, useState } from 'react';\nimport {\n EdsHeader,\n EdsSplashScreen,\n EdsMatomoNotice,\n EdsSteps\n} from '@ebrains/react';\nimport './app.css';\n\n// simulate 2s\nfunction fakeInit(): Promise<void> {\n return new Promise(resolve => setTimeout(resolve, 2000));\n}\n\nexport function App() {\n // 1) create init promise\n const initPromise = useMemo(() => fakeInit(), []);\n\n // 2) is splash still visible\n const [splashVisible, setSplashVisible] = useState(true);\n const [initError, setInitError] = useState<string | null>(null);\n\n // 3) show the UI after the splash has hidden\n const showApp = !splashVisible && !initError;\n\n return (\n <div>\n {splashVisible && (\n <EdsSplashScreen\n inverse={false}\n initPromise={initPromise}\n onSplash={(e: CustomEvent) => {\n if (e.detail.type === 'hidden') {\n setSplashVisible(false);\n } else if (e.detail.type === 'error') {\n setInitError(e.detail.message);\n setSplashVisible(false);\n }\n }}\n />\n )}\n\n {initError && (\n <div className='error'>\n Failed to initialize: {initError}\n </div>\n )}\n\n {/* Show App only when ready */}\n {showApp && (\n <>\n <EdsHeader></EdsHeader>\n <EdsSteps\n steps={[\n {\n title: 'Introduction',\n content: 'Begin by familiarizing yourself with the overall process.'\n },\n {\n title: 'Process Overview',\n content: 'Review the detailed steps and understand the workflow.'\n }\n ]}\n type='linear'\n />\n\n <EdsMatomoNotice />\n\n <div id='root'></div>\n </>\n )}\n </div>\n );\n}\nexport default App;\n",
|
|
89
89
|
language: "javascript",
|
|
90
90
|
"copy-label": "Copy Code"
|
|
91
91
|
})));
|
|
@@ -70,21 +70,21 @@ const EdsAccordion = class {
|
|
|
70
70
|
*/
|
|
71
71
|
render() {
|
|
72
72
|
return h("div", {
|
|
73
|
-
key: '
|
|
73
|
+
key: 'addeb5f79d497efcd3eab9f849890adf48a5e275',
|
|
74
74
|
ref: el => this.wrapperRef = el,
|
|
75
75
|
class: `flex effect-color border-softer relative grid overflow-hidden rounded-lg border-2 p-16
|
|
76
76
|
${this.switchBg && this.isExpanded ? 'bg-inverse' : 'bg-default'}
|
|
77
77
|
${this.switchBg ? 'hover:bg-inverse' : ''}
|
|
78
78
|
${this.description ? 'min-h-56' : ''}`
|
|
79
79
|
}, h("h3", {
|
|
80
|
-
key: '
|
|
80
|
+
key: 'c522c074c205e471f9e95991a03f703bec8d3219',
|
|
81
81
|
ref: el => this.headerRef = el,
|
|
82
82
|
class: "mr-auto f-heading-06 text-left absolute inset-x-16 break-words top-16 pr-40"
|
|
83
83
|
}, this.heading), h("div", {
|
|
84
|
-
key: '
|
|
84
|
+
key: '5ee474856bf9a3cdc732c27c6fccb68c24e0dc3b',
|
|
85
85
|
class: "ml-auto"
|
|
86
86
|
}, h("eds-button", {
|
|
87
|
-
key: '
|
|
87
|
+
key: 'a274b1d82f30607f61103433aa6ceb745464f530',
|
|
88
88
|
id: "toggleAccordion",
|
|
89
89
|
intent: "tertiary",
|
|
90
90
|
"aria-expanded": this.isExpanded || this.shortContent,
|
|
@@ -94,7 +94,7 @@ const EdsAccordion = class {
|
|
|
94
94
|
onClick: this.handleClick,
|
|
95
95
|
icon: "chevron-down"
|
|
96
96
|
})), h("div", {
|
|
97
|
-
key: '
|
|
97
|
+
key: '69a638f2dc3c5ebff95fc4049c47abd4884b13ad',
|
|
98
98
|
class: `w-full`,
|
|
99
99
|
style: Number.isFinite(this.headerHeight) ? {
|
|
100
100
|
marginTop: `${this.headerHeight}px`
|
|
@@ -102,7 +102,7 @@ const EdsAccordion = class {
|
|
|
102
102
|
}, this.description ? h("span", {
|
|
103
103
|
class: `text-light ${!this.isExpanded && this.clampText ? 'line-clamp-1' : ''}`
|
|
104
104
|
}, this.description) : null, h("section", {
|
|
105
|
-
key: '
|
|
105
|
+
key: '820f39174c6e6d42e7c4407a2a4175fb077f86ac',
|
|
106
106
|
id: "accordionSection",
|
|
107
107
|
role: "region",
|
|
108
108
|
"aria-labelledby": "accordionHeader",
|
|
@@ -112,15 +112,15 @@ const EdsAccordion = class {
|
|
|
112
112
|
height: this.isExpanded ? 'auto' : '0'
|
|
113
113
|
}
|
|
114
114
|
}, h("div", {
|
|
115
|
-
key: '
|
|
115
|
+
key: '3d9ea33856d350434d26c07ddc9d230e28d8c344',
|
|
116
116
|
ref: el => this.childContentRef = el,
|
|
117
117
|
class: `accordion-content effect-color pt-4`,
|
|
118
118
|
"aria-hidden": !this.isExpanded
|
|
119
119
|
}, h("span", {
|
|
120
|
-
key: '
|
|
120
|
+
key: '1d0761d7894d5ba4d7c7f5051031857555ce0b0c',
|
|
121
121
|
class: `${!this.isExpanded && this.clampText ? 'line-clamp-2' : ''}`
|
|
122
122
|
}, h("slot", {
|
|
123
|
-
key: '
|
|
123
|
+
key: 'ed31f44736a8ce85a7df4216b2f90c2ca7d9b873'
|
|
124
124
|
}))))));
|
|
125
125
|
}
|
|
126
126
|
get el() {
|
package/eds-alert.entry.esm.js
CHANGED
|
@@ -83,7 +83,7 @@ const EdsAlert = class {
|
|
|
83
83
|
}
|
|
84
84
|
render() {
|
|
85
85
|
return h("div", {
|
|
86
|
-
key: '
|
|
86
|
+
key: '5252aca583e87d8c3249c501e55368e340ef0d64',
|
|
87
87
|
class: alertStyles({
|
|
88
88
|
intent: this.intent,
|
|
89
89
|
brd: this.brd,
|
|
@@ -92,7 +92,7 @@ const EdsAlert = class {
|
|
|
92
92
|
}),
|
|
93
93
|
role: "alert"
|
|
94
94
|
}, h("p", {
|
|
95
|
-
key: '
|
|
95
|
+
key: 'bb23c94e802ec5e287a2b8619277e83de173b498',
|
|
96
96
|
class: "f-ui-01 py-8",
|
|
97
97
|
innerHTML: this.message
|
|
98
98
|
}), this.withBtn && (this.pressableUrl ? h("eds-link", {
|