@bbl-digital/snorre 3.1.27 → 3.1.28

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/dist/bundle.js CHANGED
@@ -551,7 +551,10 @@
551
551
 
552
552
  /** @jsxImportSource @emotion/react */
553
553
 
554
- const Card = props => {
554
+ const Card = ({
555
+ className,
556
+ ...props
557
+ }) => {
555
558
  const handleOnKeyPress = e => {
556
559
  if (e.key === exports.Key.enter || e.key === exports.Key.space) {
557
560
  if (props.onClick) {
@@ -565,6 +568,7 @@
565
568
  tabIndex: props.onClick ? 0 : undefined,
566
569
  onClick: props.onClick,
567
570
  onKeyPress: handleOnKeyPress,
571
+ className: className,
568
572
  children: props.children
569
573
  });
570
574
  };
@@ -4,7 +4,10 @@ import { styles } from './styles';
4
4
  import { Key } from '../../enums/Keyboard';
5
5
  import { jsx as _jsx } from "@emotion/react/jsx-runtime";
6
6
 
7
- const Card = props => {
7
+ const Card = ({
8
+ className,
9
+ ...props
10
+ }) => {
8
11
  const handleOnKeyPress = e => {
9
12
  if (e.key === Key.enter || e.key === Key.space) {
10
13
  if (props.onClick) {
@@ -18,6 +21,7 @@ const Card = props => {
18
21
  tabIndex: props.onClick ? 0 : undefined,
19
22
  onClick: props.onClick,
20
23
  onKeyPress: handleOnKeyPress,
24
+ className: className,
21
25
  children: props.children
22
26
  });
23
27
  };
@@ -24,6 +24,8 @@ declare type IProps = {
24
24
  overflowvisible?: boolean;
25
25
  /** Override with custom CSS */
26
26
  css?: SerializedStyles;
27
+ /** Classname prop */
28
+ className?: string;
27
29
  /** Children */
28
30
  children?: React.ReactNode | React.ReactNode[];
29
31
  };
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/packages/core/Card/index.tsx"],"names":[],"mappings":"AAAA,sCAAsC;AACtC,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAA;A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AS,CAAC,EAAE,OAAO,CAAA;IACnB,iCAAiC;IACjC,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,yBAAyB;IACzB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,0CAA0C;IAC1C,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,+CAA+C;IAC/C,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,6BAA6B;IAC7B,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB,+BAA+B;IAC/B,GAAG,CAAC,EAAE,gBAAgB,CAAA;IACtB,qBAAqB;IACrB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,eAAe;IACf,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,GAAG,KAAK,CAAC,SAAS,EAAE,CAAA;CAC/C,CAAA;AAED,QAAA,MAAM,IAAI,EAAE,KAAK,CAAC,EAAE,CAAC,MAAM,CAgC1B,CAAA;AAED,eAAe,IAAI,CAAA"}
@@ -4,7 +4,10 @@ import { styles } from './styles';
4
4
  import { Key } from '../../enums/Keyboard';
5
5
  import { jsx as _jsx } from "@emotion/react/jsx-runtime";
6
6
 
7
- const Card = props => {
7
+ const Card = ({
8
+ className,
9
+ ...props
10
+ }) => {
8
11
  const handleOnKeyPress = e => {
9
12
  if (e.key === Key.enter || e.key === Key.space) {
10
13
  if (props.onClick) {
@@ -18,6 +21,7 @@ const Card = props => {
18
21
  tabIndex: props.onClick ? 0 : undefined,
19
22
  onClick: props.onClick,
20
23
  onKeyPress: handleOnKeyPress,
24
+ className: className,
21
25
  children: props.children
22
26
  });
23
27
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bbl-digital/snorre",
3
- "version": "3.1.27",
3
+ "version": "3.1.28",
4
4
  "description": "Design library for BBL Digital",
5
5
  "license": "MIT",
6
6
  "main": "./lib/index.js",
@@ -46,6 +46,7 @@
46
46
  "prettier:check": "prettier --list-different src/**/*.{js,ts,tsx}",
47
47
  "storybook": "start-storybook -p 9009",
48
48
  "start": "yarn storybook",
49
+ "theme": "node ./theme-generator.js",
49
50
  "build-storybook": "build-storybook",
50
51
  "build": "yarn run build:cjs && yarn run build:esm && yarn run build:umd && yarn run build:tsc",
51
52
  "build:tsc": "tsc -p ./src/packages/tsconfig.json",
@@ -230,7 +230,7 @@ const updateBbl = (
230
230
  fs.writeFileSync('themes/' + bbl + '/styles.json', data)
231
231
  }
232
232
 
233
- export const bbls = [
233
+ const bbls = [
234
234
  {
235
235
  bbl: 'arendal',
236
236
  theme: {
@@ -370,9 +370,18 @@ export const bbls = [
370
370
  {
371
371
  bbl: 'abbl',
372
372
  theme: {
373
- primary: '#227F48',
374
- secondary: '#213228',
373
+ primary: '#de6364',
374
+ secondary: '#75b474',
375
375
  alpha: '0.02',
376
+
377
+ secondaryFooter: true,
378
+ sidemenuColor: '#004933',
379
+ sidemenuItemColor: '#007f59',
380
+ submenuColor: '#F5F2EB',
381
+ submenuItemColor: '#75b474',
382
+ submenuTextColor: 'rgba(0, 0, 0, 0.7)',
383
+ submenuTextColorActive: 'black',
384
+ customBgColor: '#FCFBF8',
376
385
  },
377
386
  },
378
387
  {
@@ -418,17 +427,17 @@ export const bbls = [
418
427
  {
419
428
  bbl: 'sorbbl',
420
429
  theme: {
421
- primary: '#0075B2',
422
- secondary: '#00527C',
423
- alpha: '0.02',
430
+ primary: '#006ED2',
431
+ secondary: '#001A41',
432
+ alpha: '0.04',
424
433
  },
425
434
  },
426
435
  {
427
436
  bbl: 'sbbl',
428
437
  theme: {
429
- primary: '#0075B2',
430
- secondary: '#00527C',
431
- alpha: '0.02',
438
+ primary: '#006ED2',
439
+ secondary: '#001A41',
440
+ alpha: '0.04',
432
441
  },
433
442
  },
434
443
  {
@@ -619,4 +628,7 @@ export const bbls = [
619
628
  },
620
629
  ]
621
630
 
631
+ // export bbls with es5
632
+ module.exports = bbls
633
+
622
634
  updateTheme()