@reykjavik/hanna-react 0.10.143 → 0.10.144

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/Alert.d.ts CHANGED
@@ -7,14 +7,8 @@ export type AlertI18n = {
7
7
  closeLabelLong?: string;
8
8
  };
9
9
  export declare const defaultAlertTexts: DefaultTexts<AlertI18n>;
10
- export declare const alertTypes: {
11
- info: number;
12
- success: number;
13
- warning: number;
14
- error: number;
15
- critical: number;
16
- };
17
- type AlertType = keyof typeof alertTypes;
10
+ type AlertType = 'info' | 'success' | 'warning' | 'error' | 'critical';
11
+ export declare const alertTypes: Record<string, 1>;
18
12
  export type AlertProps = {
19
13
  type: AlertType;
20
14
  closable?: boolean;
package/CHANGELOG.md CHANGED
@@ -4,10 +4,17 @@
4
4
 
5
5
  - ... <!-- Add new lines here. -->
6
6
 
7
+ ## 0.10.144
8
+
9
+ _2024-12-18_
10
+
11
+ - `Alert`:
12
+ - feat: (TS) Change `alertTypes` into `Record<string, 1>` for easier use
13
+
7
14
  ## 0.10.143
8
15
 
9
16
  _2024-12-06_
10
- +
17
+
11
18
  - `Datepicker:`
12
19
  - fix: Timezone mismatch in `isoMode` (emitted UTC-based dates, not local)
13
20
 
package/esm/Alert.d.ts CHANGED
@@ -7,14 +7,8 @@ export type AlertI18n = {
7
7
  closeLabelLong?: string;
8
8
  };
9
9
  export declare const defaultAlertTexts: DefaultTexts<AlertI18n>;
10
- export declare const alertTypes: {
11
- info: number;
12
- success: number;
13
- warning: number;
14
- error: number;
15
- critical: number;
16
- };
17
- type AlertType = keyof typeof alertTypes;
10
+ type AlertType = 'info' | 'success' | 'warning' | 'error' | 'critical';
11
+ export declare const alertTypes: Record<string, 1>;
18
12
  export type AlertProps = {
19
13
  type: AlertType;
20
14
  closable?: boolean;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@reykjavik/hanna-react",
3
- "version": "0.10.143",
3
+ "version": "0.10.144",
4
4
  "author": "Reykjavík (http://www.reykjavik.is)",
5
5
  "contributors": [
6
6
  "Hugsmiðjan ehf (http://www.hugsmidjan.is)",