@momentum-design/components 0.16.17 → 0.16.18

Sign up to get free protection for your applications and to get access to all the features.
@@ -8,6 +8,7 @@ export { default as Divider } from './divider';
8
8
  export { default as FormfieldWrapper } from './formfieldwrapper';
9
9
  export { default as Icon } from './icon';
10
10
  export { default as IconProvider } from './iconprovider';
11
+ export { default as Link } from './link';
11
12
  export { default as Marker } from './marker';
12
13
  export { default as Modalcontainer } from './modalcontainer';
13
14
  export { default as Presence } from './presence';
@@ -8,6 +8,7 @@ export { default as Divider } from './divider';
8
8
  export { default as FormfieldWrapper } from './formfieldwrapper';
9
9
  export { default as Icon } from './icon';
10
10
  export { default as IconProvider } from './iconprovider';
11
+ export { default as Link } from './link';
11
12
  export { default as Marker } from './marker';
12
13
  export { default as Modalcontainer } from './modalcontainer';
13
14
  export { default as Presence } from './presence';
@@ -0,0 +1,29 @@
1
+ import Component from '../../components/link';
2
+ /**
3
+ * `mdc-link` component can be used to navigate to a different page
4
+ * within the application or to an external site. It can be used to link to
5
+ * emails or phone numbers.
6
+ *
7
+ * The `children` of the link component is expected to be an anchor element
8
+ * containing the text, href, and other attributes.
9
+ *
10
+ * For `icon`, the `mdc-icon` component is used to render the icon.
11
+ *
12
+ * @dependency mdc-icon
13
+ *
14
+ * @tagname mdc-link
15
+ *
16
+ * @cssproperty --mdc-link-border-radius - Border radius of the link
17
+ * @cssproperty --mdc-link-color-active - Text and icon color of the link in active state
18
+ * @cssproperty --mdc-link-color-disabled - Text and icon color of the link in disabled state
19
+ * @cssproperty --mdc-link-color-hover - Text and icon color of the link in hover state
20
+ * @cssproperty --mdc-link-color-normal - Text and icon color of the link in normal state
21
+ * @cssproperty --mdc-link-icon-margin-left - Gap between the text and icon (only applicable when an icon is set)
22
+ * @cssproperty --mdc-link-inverted-color-active - Text and icon color of the inverted link in active state
23
+ * @cssproperty --mdc-link-inverted-color-disabled - Text and icon color of the inverted link in disabled state
24
+ * @cssproperty --mdc-link-inverted-color-hover - Text and icon color of the inverted link in hover state
25
+ * @cssproperty --mdc-link-inverted-color-normal - Text and icon color of the inverted link in normal state
26
+ * @cssproperty --mdc-link-text-decoration-disabled - Text decoration of the link in disabled state for all variants
27
+ */
28
+ declare const reactWrapper: import("@lit/react").ReactWebComponent<Component, {}>;
29
+ export default reactWrapper;
@@ -0,0 +1,38 @@
1
+ import * as React from 'react';
2
+ import { createComponent } from '@lit/react';
3
+ import Component from '../../components/link';
4
+ import { TAG_NAME } from '../../components/link/link.constants';
5
+ /**
6
+ * `mdc-link` component can be used to navigate to a different page
7
+ * within the application or to an external site. It can be used to link to
8
+ * emails or phone numbers.
9
+ *
10
+ * The `children` of the link component is expected to be an anchor element
11
+ * containing the text, href, and other attributes.
12
+ *
13
+ * For `icon`, the `mdc-icon` component is used to render the icon.
14
+ *
15
+ * @dependency mdc-icon
16
+ *
17
+ * @tagname mdc-link
18
+ *
19
+ * @cssproperty --mdc-link-border-radius - Border radius of the link
20
+ * @cssproperty --mdc-link-color-active - Text and icon color of the link in active state
21
+ * @cssproperty --mdc-link-color-disabled - Text and icon color of the link in disabled state
22
+ * @cssproperty --mdc-link-color-hover - Text and icon color of the link in hover state
23
+ * @cssproperty --mdc-link-color-normal - Text and icon color of the link in normal state
24
+ * @cssproperty --mdc-link-icon-margin-left - Gap between the text and icon (only applicable when an icon is set)
25
+ * @cssproperty --mdc-link-inverted-color-active - Text and icon color of the inverted link in active state
26
+ * @cssproperty --mdc-link-inverted-color-disabled - Text and icon color of the inverted link in disabled state
27
+ * @cssproperty --mdc-link-inverted-color-hover - Text and icon color of the inverted link in hover state
28
+ * @cssproperty --mdc-link-inverted-color-normal - Text and icon color of the inverted link in normal state
29
+ * @cssproperty --mdc-link-text-decoration-disabled - Text decoration of the link in disabled state for all variants
30
+ */
31
+ const reactWrapper = createComponent({
32
+ tagName: TAG_NAME,
33
+ elementClass: Component,
34
+ react: React,
35
+ events: {},
36
+ displayName: 'Link',
37
+ });
38
+ export default reactWrapper;
@@ -56,13 +56,13 @@ const hostFocusRingStyles = (applyFocusRingOnClass = false) => {
56
56
  :host([disabled]:focus) {
57
57
  box-shadow: none;
58
58
  }
59
- :host(:focus) {
59
+ :host(:focus), :host(:focus-within) {
60
60
  position: relative;
61
61
  box-shadow: ${boxShadow};
62
62
  }
63
63
  /* High Contrast Mode */
64
64
  @media (forced-colors: active) {
65
- :host(:focus) {
65
+ :host(:focus), :host(:focus-within) {
66
66
  outline: 0.125rem solid var(--mds-color-theme-focus-default-0);
67
67
  }
68
68
  }
package/package.json CHANGED
@@ -36,5 +36,5 @@
36
36
  "lit": "^3.2.0",
37
37
  "uuid": "^11.0.5"
38
38
  },
39
- "version": "0.16.17"
39
+ "version": "0.16.18"
40
40
  }