@warp-ds/elements 2.2.0-next.7 → 2.2.0-next.9

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 (67) hide show
  1. package/dist/api.js +1 -1
  2. package/dist/api.js.map +4 -4
  3. package/dist/custom-elements.json +1826 -1424
  4. package/dist/index.d.ts +1 -0
  5. package/dist/index.js +1256 -137
  6. package/dist/index.js.map +4 -4
  7. package/dist/packages/alert/index.js.map +1 -1
  8. package/dist/packages/alert/react.js.map +1 -1
  9. package/dist/packages/attention/attention.stories.d.ts +5 -0
  10. package/dist/packages/attention/attention.test.d.ts +1 -0
  11. package/dist/packages/attention/index.d.ts +48 -89
  12. package/dist/packages/attention/index.js +3354 -16
  13. package/dist/packages/attention/index.js.map +4 -4
  14. package/dist/packages/attention/layout-styles.d.ts +1 -0
  15. package/dist/packages/attention/react.d.ts +1 -0
  16. package/dist/packages/attention/react.js +3405 -0
  17. package/dist/packages/attention/react.js.map +7 -0
  18. package/dist/packages/attention/styles.d.ts +1 -0
  19. package/dist/packages/button/index.d.ts +1 -0
  20. package/dist/packages/button/index.js +214 -9
  21. package/dist/packages/button/index.js.map +4 -4
  22. package/dist/packages/button/react.js +213 -8
  23. package/dist/packages/button/react.js.map +4 -4
  24. package/dist/packages/datepicker/DatePicker.test.d.ts +1 -0
  25. package/dist/packages/datepicker/datepicker.d.ts +9 -0
  26. package/dist/packages/datepicker/index.js +87 -83
  27. package/dist/packages/datepicker/index.js.map +3 -3
  28. package/dist/packages/datepicker/react.d.ts +2 -0
  29. package/dist/packages/datepicker/react.js +2805 -0
  30. package/dist/packages/datepicker/react.js.map +7 -0
  31. package/dist/packages/link/index.d.ts +39 -0
  32. package/dist/packages/link/index.js +2646 -0
  33. package/dist/packages/link/index.js.map +7 -0
  34. package/dist/packages/link/link.stories.d.ts +20 -0
  35. package/dist/packages/link/link.test.d.ts +1 -0
  36. package/dist/packages/link/react.d.ts +2 -0
  37. package/dist/packages/link/react.js +2666 -0
  38. package/dist/packages/link/react.js.map +7 -0
  39. package/dist/packages/link/styles.d.ts +1 -0
  40. package/dist/packages/steps/index.d.ts +43 -0
  41. package/dist/packages/steps/index.js +2465 -0
  42. package/dist/packages/steps/index.js.map +7 -0
  43. package/dist/packages/steps/locales/da/messages.d.mts +1 -0
  44. package/dist/packages/steps/locales/en/messages.d.mts +1 -0
  45. package/dist/packages/steps/locales/fi/messages.d.mts +1 -0
  46. package/dist/packages/steps/locales/nb/messages.d.mts +1 -0
  47. package/dist/packages/steps/locales/sv/messages.d.mts +1 -0
  48. package/dist/packages/steps/react.d.ts +3 -0
  49. package/dist/packages/steps/react.js +2485 -0
  50. package/dist/packages/steps/react.js.map +7 -0
  51. package/dist/packages/steps/steps.stories.d.ts +12 -0
  52. package/dist/packages/steps/styles.d.ts +1 -0
  53. package/dist/packages/textfield/index.js +1 -1
  54. package/dist/packages/textfield/index.js.map +2 -2
  55. package/dist/packages/textfield/react.js +1 -1
  56. package/dist/packages/textfield/react.js.map +2 -2
  57. package/dist/packages/toast/api.d.ts +4 -45
  58. package/dist/packages/toast/index.d.ts +3 -3
  59. package/dist/packages/toast/index.js +2461 -22
  60. package/dist/packages/toast/index.js.map +4 -4
  61. package/dist/packages/toast/styles.d.ts +1 -0
  62. package/dist/packages/toast/toast-container.d.ts +12 -78
  63. package/dist/packages/toast/toast.d.ts +16 -29
  64. package/dist/packages/toast/types.d.ts +15 -0
  65. package/dist/vscode.html-custom-data.json +86 -34
  66. package/dist/web-types.json +199 -99
  67. package/package.json +11 -9
@@ -1,54 +1,13 @@
1
- /**
2
- * Toast helper function options
3
- * @typedef {Object} ToastOptions
4
- * @property {(number|string)} [id] Custom identifier
5
- * @property {('success'|'error'|'warning')} [type] Type of toast
6
- * @property {String} [text] The toast message. Only needed when updating text on existing toast
7
- * @property {(number|string)} [duration] Duration of toast in milliseconds. Defaults to 5000. For accessibility reasons, toasts should never be interactive and therefore need to auto remove. If you must disable auto remove, set duration to Number.POSITIVE_INFINITY.
8
- * @property {Boolean} [canclose] Whether the toast can be dismissed. Defaults to false. WARNING! For accessibility reasons, toasts should not be interactive and canclose should always be false. If the toast absolutely must be dismissable, set this to true.
9
- */
1
+ import type { ToastOptions, ToastInternal } from './types';
10
2
  /**
11
3
  * Creates a new toast
12
- * @param {String} message Message
13
- * @param {ToastOptions?} options Toast options
14
- * @returns {ToastOptions} Toast details
15
4
  */
16
- export function toast(message: string, options: ToastOptions | null): ToastOptions;
5
+ export declare function toast(message: string, options?: ToastOptions): ToastOptions;
17
6
  /**
18
7
  * Remove an existing toast
19
- * @param {String|Number} id Toast identifier
20
- * @return {Promise<Boolean>} Resolves to true if deleted, false if not found
21
8
  */
22
- export function removeToast(id: string | number): Promise<boolean>;
9
+ export declare function removeToast(id: string | number): Promise<boolean> | undefined;
23
10
  /**
24
11
  * Update an existing toast
25
- * @param {String|Number} id Toast identifier
26
- * @param {ToastOptions?} options Toast options
27
- * @returns {WarpToastContainer} Toast details
28
- */
29
- export function updateToast(id: string | number, options: ToastOptions | null): WarpToastContainer;
30
- /**
31
- * Toast helper function options
32
12
  */
33
- export type ToastOptions = {
34
- /**
35
- * Custom identifier
36
- */
37
- id?: (number | string);
38
- /**
39
- * Type of toast
40
- */
41
- type?: ("success" | "error" | "warning");
42
- /**
43
- * The toast message. Only needed when updating text on existing toast
44
- */
45
- text?: string;
46
- /**
47
- * Duration of toast in milliseconds. Defaults to 5000. For accessibility reasons, toasts should never be interactive and therefore need to auto remove. If you must disable auto remove, set duration to Number.POSITIVE_INFINITY.
48
- */
49
- duration?: (number | string);
50
- /**
51
- * Whether the toast can be dismissed. Defaults to false. WARNING! For accessibility reasons, toasts should not be interactive and canclose should always be false. If the toast absolutely must be dismissable, set this to true.
52
- */
53
- canclose?: boolean;
54
- };
13
+ export declare function updateToast(id: string | number, options?: ToastOptions): ToastInternal | undefined;
@@ -1,3 +1,3 @@
1
- export { WarpToast } from "./toast";
2
- export { WarpToastContainer } from "./toast-container";
3
- export { toast, updateToast, removeToast } from "./api";
1
+ export { WarpToast } from './toast';
2
+ export { WarpToastContainer } from './toast-container';
3
+ export { toast, updateToast, removeToast } from './api';