@youversion/design-system-components 1.3.0 → 1.3.1

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.
@@ -5,6 +5,39 @@ interface Props extends Omit<AllHTMLAttributes<HTMLDivElement>, 'width' | 'heigh
5
5
  className?: ClassValue;
6
6
  variant?: BannerVariant;
7
7
  }
8
+ /**
9
+ * The **Banner** component is used to display a message to the user. It can take a component or string.
10
+ * In cases where a component like Trans is passed, style must be manually applied.
11
+ *
12
+ * Accepts {@link Props}.
13
+ *
14
+ * @returns Renders a div component, with a nested div that displays the message.
15
+ * @example
16
+ * ```tsx
17
+ * function MyComponent() {
18
+ * return (
19
+ * <>
20
+ * <Banner variant='error' className='w-[400px] mlb-3 p-2'>
21
+ * <Text className={bannerTextColorVariants.error}>
22
+ * <Trans
23
+ * components={{
24
+ a: (
25
+ <a
26
+ className={`underline ${bannerTextColorVariants.error}`}
27
+ href='https://partner-support.youversion.com/'
28
+ />
29
+ ),
30
+ }}
31
+ i18nKey='common:generic_error_message'
32
+ t={t}
33
+ />
34
+ </Text>
35
+ </Banner>
36
+ * </>
37
+ * )
38
+ * }
39
+ * ```
40
+ */
8
41
  export declare function Banner({ className, children, variant }: Props): JSX.Element;
9
42
  export {};
10
43
  //# sourceMappingURL=Banner.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Banner.d.ts","sourceRoot":"","sources":["../../../src/Banner/Banner.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAClC,OAAO,EAAE,iBAAiB,EAAW,MAAM,OAAO,CAAC;AAInD,KAAK,aAAa,GAAG,SAAS,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,GAAG,SAAS,GAAG,MAAM,CAAC;AAEnF,UAAU,KAAM,SAAQ,IAAI,CAAC,iBAAiB,CAAC,cAAc,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,WAAW,CAAC;IAC/F,SAAS,CAAC,EAAE,UAAU,CAAC;IACvB,OAAO,CAAC,EAAE,aAAa,CAAC;CACzB;AAED,wBAAgB,MAAM,CAAC,EAAE,SAAS,EAAE,QAAQ,EAAE,OAAmB,EAAE,EAAE,KAAK,eAmDzE"}
1
+ {"version":3,"file":"Banner.d.ts","sourceRoot":"","sources":["../../../src/Banner/Banner.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAClC,OAAO,EAAE,iBAAiB,EAAW,MAAM,OAAO,CAAC;AAKnD,KAAK,aAAa,GAAG,SAAS,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,GAAG,SAAS,GAAG,MAAM,CAAC;AAEnF,UAAU,KAAM,SAAQ,IAAI,CAAC,iBAAiB,CAAC,cAAc,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,WAAW,CAAC;IAC/F,SAAS,CAAC,EAAE,UAAU,CAAC;IACvB,OAAO,CAAC,EAAE,aAAa,CAAC;CACzB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AAEH,wBAAgB,MAAM,CAAC,EAAE,SAAS,EAAE,QAAQ,EAAE,OAAmB,EAAE,EAAE,KAAK,eAqBzE"}
@@ -0,0 +1,26 @@
1
+ export declare const iconWrapper: {
2
+ default: string;
3
+ error: string;
4
+ info: string;
5
+ mail: string;
6
+ success: string;
7
+ warning: string;
8
+ };
9
+ export declare const bannerBaseStyles = "flex flex-start items-center justify-start plb-2 pis-2 pie-4 rounded-1 w-full text-base leading-normal box-border gap-sm";
10
+ export declare const bannerStyleVariants: {
11
+ default: string;
12
+ error: string;
13
+ info: string;
14
+ mail: string;
15
+ success: string;
16
+ warning: string;
17
+ };
18
+ export declare const bannerTextColorVariants: {
19
+ default: string;
20
+ error: string;
21
+ info: string;
22
+ mail: string;
23
+ success: string;
24
+ warning: string;
25
+ };
26
+ //# sourceMappingURL=BannerStyles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BannerStyles.d.ts","sourceRoot":"","sources":["../../../src/Banner/BannerStyles.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,WAAW;;;;;;;CAOvB,CAAC;AAEF,eAAO,MAAM,gBAAgB,6HAC+F,CAAC;AAE7H,eAAO,MAAM,mBAAmB;;;;;;;CAO/B,CAAC;AAEF,eAAO,MAAM,uBAAuB;;;;;;;CAOnC,CAAC"}
@@ -4,7 +4,7 @@ type ToastVariant = 'success' | 'error' | 'info' | 'caution' | 'default';
4
4
  export interface ToastProps extends Omit<AllHTMLAttributes<HTMLDivElement>, 'width' | 'height' | 'className'> {
5
5
  /** May add styles around the wrapper div of this component */
6
6
  className?: string;
7
- /** Callback that is is loaded when the noitfication timesout of the dismiss button is clicked. */
7
+ /** Callback that is is loaded when the notification times out of the dismiss button is clicked. */
8
8
  dismiss?: () => void;
9
9
  /** If set, the toast will timeout automatically in milliseconds */
10
10
  duration?: number;
@@ -1 +1 @@
1
- {"version":3,"file":"Toast.d.ts","sourceRoot":"","sources":["../../../src/Toast/Toast.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,EAAE,EAAE,iBAAiB,EAAwC,MAAM,OAAO,CAAC;AAIvG,KAAK,aAAa,GAAG,WAAW,GAAG,aAAa,CAAC;AAEjD,KAAK,YAAY,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,GAAG,SAAS,GAAG,SAAS,CAAC;AAiBzE,MAAM,WAAW,UAAW,SAAQ,IAAI,CAAC,iBAAiB,CAAC,cAAc,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,WAAW,CAAC;IAC3G,8DAA8D;IAC9D,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,kGAAkG;IAClG,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,mEAAmE;IACnE,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,wHAAwH;IACxH,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,yGAAyG;IACzG,QAAQ,CAAC,EAAE,aAAa,CAAC;IACzB,uEAAuE;IACvE,OAAO,CAAC,EAAE,YAAY,CAAC;CACxB;AAED,eAAO,MAAM,KAAK,EAAE,EAAE,CAAC,iBAAiB,CAAC,UAAU,CAAC,CA+EnD,CAAC"}
1
+ {"version":3,"file":"Toast.d.ts","sourceRoot":"","sources":["../../../src/Toast/Toast.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,EAAE,EAAE,iBAAiB,EAAwC,MAAM,OAAO,CAAC;AAIvG,KAAK,aAAa,GAAG,WAAW,GAAG,aAAa,CAAC;AAEjD,KAAK,YAAY,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,GAAG,SAAS,GAAG,SAAS,CAAC;AAiBzE,MAAM,WAAW,UAAW,SAAQ,IAAI,CAAC,iBAAiB,CAAC,cAAc,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,WAAW,CAAC;IAC3G,8DAA8D;IAC9D,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,mGAAmG;IACnG,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,mEAAmE;IACnE,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,wHAAwH;IACxH,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,yGAAyG;IACzG,QAAQ,CAAC,EAAE,aAAa,CAAC;IACzB,uEAAuE;IACvE,OAAO,CAAC,EAAE,YAAY,CAAC;CACxB;AAED,eAAO,MAAM,KAAK,EAAE,EAAE,CAAC,iBAAiB,CAAC,UAAU,CAAC,CA+EnD,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@youversion/design-system-components",
3
- "version": "1.3.0",
3
+ "version": "1.3.1",
4
4
  "main": "./dist/index.umd.js",
5
5
  "module": "./dist/index.es.js",
6
6
  "types": "./dist/index.d.ts",