@db-ux/react-core-components 4.7.3 → 4.8.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/CHANGELOG.md
CHANGED
|
@@ -1,10 +1,15 @@
|
|
|
1
1
|
# @db-ux/react-core-components
|
|
2
2
|
|
|
3
|
+
## 4.8.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- Notification content now supports additional inline elements like `span` without styling collisions. And added the possibility to set the duration as a machine-readable value via the new `timestampDatetime` property - [see commit dae5149](https://github.com/db-ux-design-system/core-web/commit/dae514902f92a74cb95a3a3adab205d560174692)
|
|
8
|
+
|
|
3
9
|
## 4.7.3
|
|
4
10
|
|
|
5
11
|
_version bump_
|
|
6
12
|
|
|
7
|
-
|
|
8
13
|
## 4.7.2
|
|
9
14
|
|
|
10
15
|
### Patch Changes
|
package/README.md
CHANGED
|
@@ -30,7 +30,10 @@ Import the styles in scss or css. Based on your technology the file names could
|
|
|
30
30
|
|
|
31
31
|
```scss
|
|
32
32
|
// index.scss
|
|
33
|
-
@forward "@db-ux/core-
|
|
33
|
+
@forward "@db-ux/core-foundations/build/styles/theme/rollup"; // Palette tokens
|
|
34
|
+
@forward "@db-ux/core-foundations/build/styles/bundle"; // Semantic tokens
|
|
35
|
+
@forward "@db-ux/core-foundations/build/styles/icons/rollup"; // Icon fonts
|
|
36
|
+
@forward "@db-ux/core-components/build/styles/rollup"; // Component styling
|
|
34
37
|
```
|
|
35
38
|
|
|
36
39
|
</details>
|
|
@@ -38,8 +41,11 @@ Import the styles in scss or css. Based on your technology the file names could
|
|
|
38
41
|
<summary><strong>CSS</strong></summary>
|
|
39
42
|
|
|
40
43
|
```tsx
|
|
41
|
-
// main.tsx
|
|
42
|
-
import "@db-ux/core-
|
|
44
|
+
// main.tsx — order matters!
|
|
45
|
+
import "@db-ux/core-foundations/build/styles/theme/rollup.css"; // Palette tokens
|
|
46
|
+
import "@db-ux/core-foundations/build/styles/bundle.css"; // Semantic tokens
|
|
47
|
+
import "@db-ux/core-foundations/build/styles/icons/rollup.css"; // Icon fonts
|
|
48
|
+
import "@db-ux/core-components/build/styles/rollup.css"; // Component styling
|
|
43
49
|
```
|
|
44
50
|
|
|
45
51
|
</details>
|
|
@@ -40,6 +40,17 @@ export type DBNotificationDefaultProps = {
|
|
|
40
40
|
* The timestamp attribute can be set for overlay notifications
|
|
41
41
|
*/
|
|
42
42
|
timestamp?: string;
|
|
43
|
+
/**
|
|
44
|
+
* Machine-readable value for the `datetime` attribute of the rendered `<time>` element.
|
|
45
|
+
*
|
|
46
|
+
* Accepts any valid HTML datetime string:
|
|
47
|
+
* - Absolute moment: ISO 8601 date/time, e.g. `"2024-06-01T12:30:00"`
|
|
48
|
+
* - Duration: ISO 8601 duration, e.g. `"PT5M"` (5 minutes), `"PT1H30M"` (1 h 30 min)
|
|
49
|
+
*
|
|
50
|
+
* When omitted the `datetime` attribute is not rendered and assistive technologies
|
|
51
|
+
* fall back to the visible `timestamp` text.
|
|
52
|
+
*/
|
|
53
|
+
timestampDatetime?: string;
|
|
43
54
|
/**
|
|
44
55
|
* Enables or disables the visibility of the timestamp.
|
|
45
56
|
*/
|
|
@@ -22,9 +22,9 @@ function DBNotificationFn(props, component) {
|
|
|
22
22
|
ariaLive: props.ariaLive,
|
|
23
23
|
}), "aria-live": props.ariaLive, "data-semantic": props.semantic, "data-variant": props.variant, "data-icon": getBoolean(props.showIcon) !== false ? props.icon : undefined, "data-show-icon": getBooleanAsString(props.showIcon), "data-link-variant": props.linkVariant }),
|
|
24
24
|
React.createElement(React.Fragment, null, props.image),
|
|
25
|
-
stringPropVisible(props.headline, props.showHeadline) ? (React.createElement("header",
|
|
25
|
+
stringPropVisible(props.headline, props.showHeadline) ? (React.createElement("header", { "data-area": "head" }, props.headline)) : null,
|
|
26
26
|
React.createElement("div", { "data-area": "content" }, props.text ? React.createElement(React.Fragment, null, props.text) : React.createElement(React.Fragment, null, props.children)),
|
|
27
|
-
stringPropVisible(props.timestamp, props.showTimestamp) ? (React.createElement("
|
|
27
|
+
stringPropVisible(props.timestamp, props.showTimestamp) ? (React.createElement("time", { "data-area": "timestamp", dateTime: props.timestampDatetime }, props.timestamp)) : null,
|
|
28
28
|
React.createElement(React.Fragment, null, props.link),
|
|
29
29
|
getBoolean(props.closeable, "closeable") ? (React.createElement(DBButton, { icon: "cross", variant: "ghost", size: "small", id: props.closeButtonId, noText: true, onClick: (event) => handleClose(event) }, (_c = props.closeButtonText) !== null && _c !== void 0 ? _c : DEFAULT_CLOSE_BUTTON)) : null));
|
|
30
30
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@db-ux/react-core-components",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.8.0",
|
|
4
4
|
"description": "React components for @db-ux/core-components",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -32,8 +32,8 @@
|
|
|
32
32
|
},
|
|
33
33
|
"sideEffects": false,
|
|
34
34
|
"dependencies": {
|
|
35
|
-
"@db-ux/core-components": "4.
|
|
36
|
-
"@db-ux/core-foundations": "4.
|
|
35
|
+
"@db-ux/core-components": "4.8.0",
|
|
36
|
+
"@db-ux/core-foundations": "4.8.0"
|
|
37
37
|
},
|
|
38
38
|
"scripts": {
|
|
39
39
|
"build": "npm-run-all tsc --parallel mv:*",
|