@mmb-digital/ds-lilly 0.0.1-alpha.368 → 0.0.1-alpha.371
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/ds-lilly.css +1 -1
- package/dist/ds-lilly.js +3 -2
- package/dist/types/src/components/Components/Alert/Alert.d.ts +2 -2
- package/dist/types/src/components/Components/Avatar/Avatar.d.ts +2 -2
- package/dist/types/src/components/Components/Card/Card.d.ts +5 -5
- package/dist/types/src/components/Components/Dropdown/_elements_/DropdownItem.d.ts +2 -2
- package/dist/types/src/components/Components/Icon/Icon.d.ts +2 -2
- package/dist/types/src/components/Components/IconList/IconListItem.d.ts +2 -2
- package/dist/types/src/components/Components/Tag/Tag.d.ts +5 -3
- package/dist/types/src/components/Form/Select2/Select2.d.ts +2 -2
- package/dist/types/src/components/Form/Select2/_elements_/SelectedOption.d.ts +2 -2
- package/dist/types/src/components/Typography/Title/Title.d.ts +2 -2
- package/dist/types/src/types/colors.d.ts +3 -0
- package/dist/types/src/types/index.d.ts +1 -1
- package/package.json +6 -4
- package/dist/types/src/types/iconBackground.d.ts +0 -2
package/dist/ds-lilly.js
CHANGED
|
@@ -96683,8 +96683,9 @@ var Pills = function (_a) {
|
|
|
96683
96683
|
|
|
96684
96684
|
|
|
96685
96685
|
var Tag = function (_a) {
|
|
96686
|
-
var
|
|
96687
|
-
|
|
96686
|
+
var _b;
|
|
96687
|
+
var background = _a.background, children = _a.children, iconBackground = _a.iconBackground, iconName = _a.iconName, testId = _a.testId, theme = _a.theme;
|
|
96688
|
+
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('c-tag', (_b = { 'c-tag--withIcon': !!iconName }, _b["c-tag--" + background + "Color"] = background, _b), theme), "data-testid": testId },
|
|
96688
96689
|
iconName && external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { backgroundColor: iconBackground, name: iconName, size: "small" }),
|
|
96689
96690
|
children));
|
|
96690
96691
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ReactElement, ReactNode, RefObject } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { BackgroundColorType, IconNameType } from '../../../types';
|
|
3
3
|
import { ComponentPropsType } from '../../../utils';
|
|
4
4
|
export interface AlertPropsType extends ComponentPropsType {
|
|
5
5
|
/** Element Ref */
|
|
@@ -11,7 +11,7 @@ export interface AlertPropsType extends ComponentPropsType {
|
|
|
11
11
|
/** Icon name. */
|
|
12
12
|
iconName?: IconNameType;
|
|
13
13
|
/** Icon background color. */
|
|
14
|
-
iconBackgroundColor?:
|
|
14
|
+
iconBackgroundColor?: BackgroundColorType;
|
|
15
15
|
/** Define if you want bigger paddings. */
|
|
16
16
|
isLarge?: boolean;
|
|
17
17
|
/** Action handler for close button */
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import { IconNameType } from '../../../types';
|
|
2
|
+
import { BackgroundColorType, IconNameType } from '../../../types';
|
|
3
3
|
import { ComponentPropsType } from '../../../utils';
|
|
4
4
|
export interface AvatarPropsType extends ComponentPropsType {
|
|
5
5
|
/** Avatar size enum type */
|
|
6
6
|
size?: AvatarSizeType;
|
|
7
7
|
/** Color of avatar background - any color from palette-light */
|
|
8
|
-
background?:
|
|
8
|
+
background?: BackgroundColorType;
|
|
9
9
|
/** Avatar border */
|
|
10
10
|
border?: AvatarBorderType;
|
|
11
11
|
/** Avatar shadow */
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { KeyboardEvent, ReactNode, SyntheticEvent } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { BackgroundColorType, IconNameType } from '../../../types';
|
|
3
3
|
import { ComponentPropsType } from '../../../utils';
|
|
4
4
|
export interface CardPropsType extends ComponentPropsType {
|
|
5
5
|
/** Allow click event propagation */
|
|
6
6
|
allowEventPropagation?: boolean;
|
|
7
7
|
/** Changes background color of card. */
|
|
8
|
-
backgroundColor?:
|
|
8
|
+
backgroundColor?: CardBackgroundColorType;
|
|
9
9
|
/** Changes border color of card. */
|
|
10
|
-
borderColor?:
|
|
10
|
+
borderColor?: CardBackgroundColorType;
|
|
11
11
|
/** Children to be rendered in the Card container. */
|
|
12
12
|
children?: ReactNode;
|
|
13
13
|
/** Define card header content. */
|
|
@@ -15,7 +15,7 @@ export interface CardPropsType extends ComponentPropsType {
|
|
|
15
15
|
/** Set `true` if you want to use custom element to open/close. If you choose to do it, component is controlled by `isOpen` property. */
|
|
16
16
|
hasCustomTrigger?: boolean;
|
|
17
17
|
/** Define color for circular Icon background. */
|
|
18
|
-
iconBackgroundColor?:
|
|
18
|
+
iconBackgroundColor?: BackgroundColorType;
|
|
19
19
|
/** Define Icon name if you want some to be displayed. */
|
|
20
20
|
iconName?: IconNameType;
|
|
21
21
|
/** Define if card have collapsible content. **You must specify collapse header property**. */
|
|
@@ -40,7 +40,7 @@ export interface CardPropsType extends ComponentPropsType {
|
|
|
40
40
|
withoutRole?: boolean;
|
|
41
41
|
}
|
|
42
42
|
export declare type ShadowSizeType = 'small' | 'medium' | 'large' | 'no';
|
|
43
|
-
declare type
|
|
43
|
+
declare type CardBackgroundColorType = 'cloud' | 'grey' | 'gold' | 'primaryDark' | 'transparent';
|
|
44
44
|
export declare const Card: ({ allowEventPropagation, backgroundColor, borderColor, children, hasCustomTrigger, header: collapseHeader, iconBackgroundColor, iconName, isCollapsible, isIconAlignTop, isInteractive, isOpen, isSelected, onClick, onToggle, shadowSize, size, testId, theme, withoutRole }: CardPropsType) => JSX.Element;
|
|
45
45
|
export {};
|
|
46
46
|
//# sourceMappingURL=Card.d.ts.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React, { ReactNode } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { BackgroundColorType, ComponentPropsType, IconNameType } from '../../../../';
|
|
3
3
|
export interface DropdownItemPropsType extends ComponentPropsType {
|
|
4
4
|
/** Allow click event propagation */
|
|
5
5
|
allowEventPropagation?: boolean;
|
|
@@ -8,7 +8,7 @@ export interface DropdownItemPropsType extends ComponentPropsType {
|
|
|
8
8
|
/** Children to be rendered in the main container. */
|
|
9
9
|
children: ReactNode;
|
|
10
10
|
/** Color of icon background. */
|
|
11
|
-
iconBackground?:
|
|
11
|
+
iconBackground?: BackgroundColorType;
|
|
12
12
|
/** Icon name/type enum type. */
|
|
13
13
|
iconName?: IconNameType;
|
|
14
14
|
/** Set if item is disabled. */
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { BackgroundColorType, IconNameType } from '../../../types';
|
|
2
2
|
import { ComponentPropsType } from '../../../utils/classBinder';
|
|
3
3
|
export interface IconPropsType extends ComponentPropsType {
|
|
4
4
|
/** Color of icon background */
|
|
5
|
-
backgroundColor?:
|
|
5
|
+
backgroundColor?: BackgroundColorType;
|
|
6
6
|
/** Color of icon SVG fill from palette--(light|dark).scss example orangeDark */
|
|
7
7
|
color?: string;
|
|
8
8
|
/** Icon name/type enum type */
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { ReactElement } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { BackgroundColorType, IconNameType } from '../../../types';
|
|
3
3
|
import { ComponentPropsType } from '../../../utils';
|
|
4
4
|
export declare type SizeType = 'large' | 'small';
|
|
5
5
|
export interface IconListItemPropsType extends ComponentPropsType {
|
|
6
6
|
/** Children to be rendered in the main container. */
|
|
7
7
|
children: ReactElement;
|
|
8
8
|
/** Color of icon background */
|
|
9
|
-
iconBackgroundColor?:
|
|
9
|
+
iconBackgroundColor?: BackgroundColorType;
|
|
10
10
|
/** Custom icon name */
|
|
11
11
|
iconName?: IconNameType;
|
|
12
12
|
/** Specific size for icon only */
|
|
@@ -1,13 +1,15 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { BackgroundColorType, IconNameType } from '../../../types';
|
|
3
3
|
import { ComponentPropsType } from '../../../utils';
|
|
4
4
|
export interface TagPropsType extends ComponentPropsType {
|
|
5
|
+
/** Color of tag background - any color from palette-light */
|
|
6
|
+
background?: BackgroundColorType;
|
|
5
7
|
/** Tag icon name */
|
|
6
8
|
iconName?: IconNameType;
|
|
7
9
|
/** Tag icon background color */
|
|
8
|
-
iconBackground?:
|
|
10
|
+
iconBackground?: BackgroundColorType;
|
|
9
11
|
/** Tag content (text) */
|
|
10
12
|
children: ReactNode;
|
|
11
13
|
}
|
|
12
|
-
export declare const Tag: ({ children, iconBackground, iconName, testId, theme }: TagPropsType) => JSX.Element;
|
|
14
|
+
export declare const Tag: ({ background, children, iconBackground, iconName, testId, theme }: TagPropsType) => JSX.Element;
|
|
13
15
|
//# sourceMappingURL=Tag.d.ts.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { BackgroundColorType, FormField2PropsType, IconNameType, Theme } from '../../../types';
|
|
3
3
|
export interface Select2PropsType extends FormField2PropsType {
|
|
4
4
|
/** Displays additional information for selected option. (perex, amount) */
|
|
5
5
|
displayDetails?: boolean;
|
|
@@ -16,7 +16,7 @@ export interface ItemType {
|
|
|
16
16
|
/** Optional value for withAmount variant. */
|
|
17
17
|
amount?: ReactNode;
|
|
18
18
|
/** Color of icon background. */
|
|
19
|
-
iconBackground?:
|
|
19
|
+
iconBackground?: BackgroundColorType;
|
|
20
20
|
/** Icon name/type enum type. */
|
|
21
21
|
iconName?: IconNameType;
|
|
22
22
|
/** Flag to indicate disabled item. */
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { BackgroundColorType, IconNameType } from '../../../../types';
|
|
3
3
|
export interface SelectedOptionPropsType {
|
|
4
4
|
/** Optional value for withAmount variant. */
|
|
5
5
|
amount?: ReactNode;
|
|
6
6
|
/** Color of icon background. */
|
|
7
|
-
iconBackground?:
|
|
7
|
+
iconBackground?: BackgroundColorType;
|
|
8
8
|
/** Icon name/type enum type. */
|
|
9
9
|
iconName?: IconNameType;
|
|
10
10
|
/** Label of list option. */
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { BackgroundColorType, ComponentPropsType, IconNameType } from '../../../';
|
|
3
3
|
export interface TitlePropsType extends ComponentPropsType {
|
|
4
4
|
/** Children to be rendered in the main container. */
|
|
5
5
|
children?: ReactNode;
|
|
6
6
|
/** Icon name/type enum type */
|
|
7
7
|
iconName?: IconNameType;
|
|
8
8
|
/** Color of icon background */
|
|
9
|
-
iconBackgroundColor?:
|
|
9
|
+
iconBackgroundColor?: BackgroundColorType;
|
|
10
10
|
/** Size of title. Used for it's basic purpose = defining page navigation priority. Please follow standard **[rules](https://www.w3.org/WAI/test-evaluate/preliminary/#headings)**. */
|
|
11
11
|
size: TitleSize;
|
|
12
12
|
/** Title visual size. Use this for matching title visual with desired design. */
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export declare type ColorType = 'redLightest' | 'redNormal' | 'redDark' | 'redDarker' | 'redHover' | 'redActive' | 'greenLightest' | 'greenNormal' | 'greenDark' | 'greenDarker' | 'greenDarkest' | 'greenHover' | 'greenActive' | 'orangeLightest' | 'orangeNormal' | 'orangeDark' | 'orangeDarker' | 'orangeHover' | 'orangeActive' | 'primaryLightest' | 'primaryLighter' | 'primaryLight' | 'primaryNormal' | 'primaryDark' | 'primaryDarker' | 'primaryDarkest' | 'primaryHover' | 'primaryActive' | 'cloudLightest' | 'cloudLighter' | 'cloudLight' | 'cloudNormal' | 'cloudDark' | 'cloudDarker' | 'cloudHover' | 'cloudActive' | 'secondaryLightest' | 'secondaryLighter' | 'secondaryLight' | 'secondaryNormal' | 'secondaryDark' | 'secondaryDarker' | 'secondaryDarkest' | 'secondaryHover' | 'secondaryActive' | 'greyLightest' | 'greyLighter' | 'greyLight' | 'greyNormal' | 'greyDark' | 'greyDarker' | 'greyDarkest' | 'greyHover' | 'greyActive' | 'goldNormal' | 'goldDark' | 'goldDarker' | 'whiteNormal' | 'blackNormal' | 'categoryYellow' | 'categoryOrange' | 'categoryPink' | 'categoryCherry' | 'categoryViolet' | 'categoryOceanBlue' | 'categorySkyBlue' | 'categoryMidnightBlue' | 'categorySemiBlue' | 'categoryTorquise' | 'categoryMintGreen' | 'categoryForestGreen' | 'categoryOliveGreen' | 'thirdPartyFacebook' | 'thirdPartyTwitter';
|
|
2
|
+
export declare type BackgroundColorType = 'info' | 'warning' | 'error' | 'success' | 'blueRed' | 'blueRedDark' | 'redLightest' | 'redNormal' | 'redDark' | 'redDarker' | 'redHover' | 'redActive' | 'greenLightest' | 'greenNormal' | 'greenDark' | 'greenDarker' | 'greenDarkest' | 'greenHover' | 'greenActive' | 'orangeLightest' | 'orangeNormal' | 'orangeDark' | 'orangeDarker' | 'orangeHover' | 'orangeActive' | 'primaryLightest' | 'primaryLighter' | 'primaryLight' | 'primaryNormal' | 'primaryDark' | 'primaryDarker' | 'primaryDarkest' | 'primaryHover' | 'primaryActive' | 'cloudLightest' | 'cloudLighter' | 'cloudLight' | 'cloudNormal' | 'cloudDark' | 'cloudDarker' | 'cloudHover' | 'cloudActive' | 'secondaryLightest' | 'secondaryLighter' | 'secondaryLight' | 'secondaryNormal' | 'secondaryDark' | 'secondaryDarker' | 'secondaryDarkest' | 'secondaryHover' | 'secondaryActive' | 'greyLightest' | 'greyLighter' | 'greyLight' | 'greyNormal' | 'greyDark' | 'greyDarker' | 'greyDarkest' | 'greyHover' | 'greyActive' | 'goldNormal' | 'goldDark' | 'goldDarker' | 'whiteNormal' | 'blackNormal' | 'categoryYellow' | 'categoryOrange' | 'categoryPink' | 'categoryCherry' | 'categoryViolet' | 'categoryOceanBlue' | 'categorySkyBlue' | 'categoryMidnightBlue' | 'categorySemiBlue' | 'categoryTorquise' | 'categoryMintGreen' | 'categoryForestGreen' | 'categoryOliveGreen' | 'thirdPartyFacebook' | 'thirdPartyTwitter';
|
|
3
|
+
//# sourceMappingURL=colors.d.ts.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mmb-digital/ds-lilly",
|
|
3
|
-
"version": "0.0.1-alpha.
|
|
3
|
+
"version": "0.0.1-alpha.371",
|
|
4
4
|
"description": "MMB LILLY design system",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -12,18 +12,20 @@
|
|
|
12
12
|
"dist"
|
|
13
13
|
],
|
|
14
14
|
"scripts": {
|
|
15
|
-
"build": "yarn && yarn generate
|
|
15
|
+
"build": "yarn && yarn generate && webpack --mode production --config webpack.config.js && yarn lint:fix",
|
|
16
16
|
"check:c": "yarn lint:fix && git add -A",
|
|
17
17
|
"check:p": "yarn test:check",
|
|
18
18
|
"fixme": "node ./scripts/fixme.js",
|
|
19
19
|
"generate:comp": "plop --plopfile ./scripts/plopfile.js && yarn generate:index",
|
|
20
|
+
"generate:colors": "node ./scripts/processColors",
|
|
20
21
|
"generate:icons": "node ./scripts/processIcons && svgr -d src/components/Components/Icon/_parts_/ dist/svg/",
|
|
21
22
|
"generate:index": "node ./scripts/createIndex",
|
|
23
|
+
"generate": "yarn generate:colors && yarn generate:icons && yarn generate:index",
|
|
22
24
|
"lint:fix": "yarn tslint --fix && yarn stylelint --fix",
|
|
23
25
|
"lint": "yarn tslint && yarn stylelint",
|
|
24
26
|
"prepare": "husky install",
|
|
25
|
-
"start:silent": "yarn generate
|
|
26
|
-
"start": "yarn && yarn generate
|
|
27
|
+
"start:silent": "yarn generate && yarn storybook:ci",
|
|
28
|
+
"start": "yarn && yarn generate && yarn storybook",
|
|
27
29
|
"storybook:build": "build-storybook",
|
|
28
30
|
"storybook:ci": "start-storybook -p 6006 --ci",
|
|
29
31
|
"storybook": "start-storybook -p 6006",
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
export declare type IconBackgroundType = 'info' | 'warning' | 'error' | 'success' | 'blueRed' | 'blueRedDark' | 'redLightest' | 'redNormal' | 'redDark' | 'redDarker' | 'redHover' | 'redActive' | 'greenLightest' | 'greenNormal' | 'greenDark' | 'greenDarker' | 'greenDarkest' | 'greenHover' | 'greenActive' | 'orangeLightest' | 'orangeNormal' | 'orangeDark' | 'orangeDarker' | 'orangeHover' | 'orangeActive' | 'primaryLightest' | 'primaryLighter' | 'primaryLight' | 'primaryNormal' | 'primaryDark' | 'primaryDarker' | 'primaryDarkest' | 'primaryHover' | 'primaryActive' | 'cloudLightest' | 'cloudLighter' | 'cloudLight' | 'cloudNormal' | 'cloudDark' | 'cloudDarker' | 'cloudHover' | 'cloudActive' | 'secondaryLightest' | 'secondaryLighter' | 'secondaryLight' | 'secondaryNormal' | 'secondaryDark' | 'secondaryDarker' | 'secondaryDarkest' | 'secondaryHover' | 'secondaryActive' | 'greyLightest' | 'greyLighter' | 'greyLight' | 'greyNormal' | 'greyDark' | 'greyDarker' | 'greyDarkest' | 'greyHover' | 'greyActive' | 'goldNormal' | 'goldDark' | 'goldDarker' | 'whiteNormal' | 'blackNormal' | 'categoryYellow' | 'categoryOrange' | 'categoryPink' | 'categoryCherry' | 'categoryViolet' | 'categoryOceanBlue' | 'categorySkyBlue' | 'categoryMidnightBlue' | 'categorySemiBlue' | 'categoryTorquise' | 'categoryMintGreen' | 'categoryForestGreen' | 'categoryOliveGreen' | 'thirdPartyFacebook' | 'thirdPartyTwitter';
|
|
2
|
-
//# sourceMappingURL=iconBackground.d.ts.map
|