@instructure/ui-link 9.5.2-snapshot-1 → 9.5.2-snapshot-7
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/CHANGELOG.md +10 -2
- package/es/Link/theme.js +7 -6
- package/lib/Link/theme.js +7 -6
- package/package.json +16 -16
- package/src/Link/theme.ts +6 -6
- package/tsconfig.build.tsbuildinfo +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,9 +3,17 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
-
## [9.5.2-snapshot-
|
|
6
|
+
## [9.5.2-snapshot-7](https://github.com/instructure/instructure-ui/compare/v9.5.1...v9.5.2-snapshot-7) (2024-07-31)
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
|
|
9
|
+
### Features
|
|
10
|
+
|
|
11
|
+
* **many:** rewrite color system ([1e5809e](https://github.com/instructure/instructure-ui/commit/1e5809e28dee8c2a71703a429609b8d2f95d76e6))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
### BREAKING CHANGES
|
|
15
|
+
|
|
16
|
+
* **many:** Breaks color overrides in certain cases
|
|
9
17
|
|
|
10
18
|
|
|
11
19
|
|
package/es/Link/theme.js
CHANGED
|
@@ -29,6 +29,7 @@ import { darken } from '@instructure/ui-color-utils';
|
|
|
29
29
|
* @return {Object} The final theme object with the overrides and component variables
|
|
30
30
|
*/
|
|
31
31
|
const generateComponentTheme = theme => {
|
|
32
|
+
var _colors$contrasts, _colors$contrasts2, _colors$contrasts3, _colors$contrasts4, _colors$contrasts5, _colors$contrasts6;
|
|
32
33
|
const colors = theme.colors,
|
|
33
34
|
borders = theme.borders,
|
|
34
35
|
typography = theme.typography,
|
|
@@ -53,19 +54,19 @@ const generateComponentTheme = theme => {
|
|
|
53
54
|
const componentVariables = {
|
|
54
55
|
fontFamily: typography === null || typography === void 0 ? void 0 : typography.fontFamily,
|
|
55
56
|
fontWeight: typography === null || typography === void 0 ? void 0 : typography.fontWeightNormal,
|
|
56
|
-
color: colors === null || colors === void 0 ? void 0 : colors.
|
|
57
|
+
color: colors === null || colors === void 0 ? void 0 : (_colors$contrasts = colors.contrasts) === null || _colors$contrasts === void 0 ? void 0 : _colors$contrasts.blue4570,
|
|
57
58
|
textDecorationWithinText: 'underline',
|
|
58
59
|
hoverTextDecorationWithinText: 'none',
|
|
59
60
|
textDecorationOutsideText: 'none',
|
|
60
61
|
hoverTextDecorationOutsideText: 'underline',
|
|
61
62
|
focusOutlineWidth: borders === null || borders === void 0 ? void 0 : borders.widthMedium,
|
|
62
|
-
focusOutlineColor: colors === null || colors === void 0 ? void 0 : colors.
|
|
63
|
+
focusOutlineColor: colors === null || colors === void 0 ? void 0 : (_colors$contrasts2 = colors.contrasts) === null || _colors$contrasts2 === void 0 ? void 0 : _colors$contrasts2.blue4570,
|
|
63
64
|
focusOutlineStyle: borders === null || borders === void 0 ? void 0 : borders.style,
|
|
64
65
|
focusOutlineBorderRadius: borders === null || borders === void 0 ? void 0 : borders.radiusSmall,
|
|
65
|
-
hoverColor: darken(colors === null || colors === void 0 ? void 0 : colors.
|
|
66
|
-
colorInverse: colors === null || colors === void 0 ? void 0 : colors.
|
|
67
|
-
focusInverseOutlineColor: colors === null || colors === void 0 ? void 0 : colors.
|
|
68
|
-
focusInverseIconOutlineColor: colors === null || colors === void 0 ? void 0 : colors.
|
|
66
|
+
hoverColor: darken(colors === null || colors === void 0 ? void 0 : (_colors$contrasts3 = colors.contrasts) === null || _colors$contrasts3 === void 0 ? void 0 : _colors$contrasts3.blue5782, 10),
|
|
67
|
+
colorInverse: colors === null || colors === void 0 ? void 0 : (_colors$contrasts4 = colors.contrasts) === null || _colors$contrasts4 === void 0 ? void 0 : _colors$contrasts4.grey1111,
|
|
68
|
+
focusInverseOutlineColor: colors === null || colors === void 0 ? void 0 : (_colors$contrasts5 = colors.contrasts) === null || _colors$contrasts5 === void 0 ? void 0 : _colors$contrasts5.white1010,
|
|
69
|
+
focusInverseIconOutlineColor: colors === null || colors === void 0 ? void 0 : (_colors$contrasts6 = colors.contrasts) === null || _colors$contrasts6 === void 0 ? void 0 : _colors$contrasts6.white1010,
|
|
69
70
|
iconSize: '1.125em',
|
|
70
71
|
// make icon slightly larger than inherited font-size,
|
|
71
72
|
iconPlusTextMargin: spacing === null || spacing === void 0 ? void 0 : spacing.xxSmall
|
package/lib/Link/theme.js
CHANGED
|
@@ -35,6 +35,7 @@ var _darken = require("@instructure/ui-color-utils/lib/darken.js");
|
|
|
35
35
|
* @return {Object} The final theme object with the overrides and component variables
|
|
36
36
|
*/
|
|
37
37
|
const generateComponentTheme = theme => {
|
|
38
|
+
var _colors$contrasts, _colors$contrasts2, _colors$contrasts3, _colors$contrasts4, _colors$contrasts5, _colors$contrasts6;
|
|
38
39
|
const colors = theme.colors,
|
|
39
40
|
borders = theme.borders,
|
|
40
41
|
typography = theme.typography,
|
|
@@ -59,19 +60,19 @@ const generateComponentTheme = theme => {
|
|
|
59
60
|
const componentVariables = {
|
|
60
61
|
fontFamily: typography === null || typography === void 0 ? void 0 : typography.fontFamily,
|
|
61
62
|
fontWeight: typography === null || typography === void 0 ? void 0 : typography.fontWeightNormal,
|
|
62
|
-
color: colors === null || colors === void 0 ? void 0 : colors.
|
|
63
|
+
color: colors === null || colors === void 0 ? void 0 : (_colors$contrasts = colors.contrasts) === null || _colors$contrasts === void 0 ? void 0 : _colors$contrasts.blue4570,
|
|
63
64
|
textDecorationWithinText: 'underline',
|
|
64
65
|
hoverTextDecorationWithinText: 'none',
|
|
65
66
|
textDecorationOutsideText: 'none',
|
|
66
67
|
hoverTextDecorationOutsideText: 'underline',
|
|
67
68
|
focusOutlineWidth: borders === null || borders === void 0 ? void 0 : borders.widthMedium,
|
|
68
|
-
focusOutlineColor: colors === null || colors === void 0 ? void 0 : colors.
|
|
69
|
+
focusOutlineColor: colors === null || colors === void 0 ? void 0 : (_colors$contrasts2 = colors.contrasts) === null || _colors$contrasts2 === void 0 ? void 0 : _colors$contrasts2.blue4570,
|
|
69
70
|
focusOutlineStyle: borders === null || borders === void 0 ? void 0 : borders.style,
|
|
70
71
|
focusOutlineBorderRadius: borders === null || borders === void 0 ? void 0 : borders.radiusSmall,
|
|
71
|
-
hoverColor: (0, _darken.darken)(colors === null || colors === void 0 ? void 0 : colors.
|
|
72
|
-
colorInverse: colors === null || colors === void 0 ? void 0 : colors.
|
|
73
|
-
focusInverseOutlineColor: colors === null || colors === void 0 ? void 0 : colors.
|
|
74
|
-
focusInverseIconOutlineColor: colors === null || colors === void 0 ? void 0 : colors.
|
|
72
|
+
hoverColor: (0, _darken.darken)(colors === null || colors === void 0 ? void 0 : (_colors$contrasts3 = colors.contrasts) === null || _colors$contrasts3 === void 0 ? void 0 : _colors$contrasts3.blue5782, 10),
|
|
73
|
+
colorInverse: colors === null || colors === void 0 ? void 0 : (_colors$contrasts4 = colors.contrasts) === null || _colors$contrasts4 === void 0 ? void 0 : _colors$contrasts4.grey1111,
|
|
74
|
+
focusInverseOutlineColor: colors === null || colors === void 0 ? void 0 : (_colors$contrasts5 = colors.contrasts) === null || _colors$contrasts5 === void 0 ? void 0 : _colors$contrasts5.white1010,
|
|
75
|
+
focusInverseIconOutlineColor: colors === null || colors === void 0 ? void 0 : (_colors$contrasts6 = colors.contrasts) === null || _colors$contrasts6 === void 0 ? void 0 : _colors$contrasts6.white1010,
|
|
75
76
|
iconSize: '1.125em',
|
|
76
77
|
// make icon slightly larger than inherited font-size,
|
|
77
78
|
iconPlusTextMargin: spacing === null || spacing === void 0 ? void 0 : spacing.xxSmall
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@instructure/ui-link",
|
|
3
|
-
"version": "9.5.2-snapshot-
|
|
3
|
+
"version": "9.5.2-snapshot-7",
|
|
4
4
|
"description": "A component for creating links",
|
|
5
5
|
"author": "Instructure, Inc. Engineering and Product Design",
|
|
6
6
|
"module": "./es/index.js",
|
|
@@ -24,24 +24,24 @@
|
|
|
24
24
|
"license": "MIT",
|
|
25
25
|
"dependencies": {
|
|
26
26
|
"@babel/runtime": "^7.24.5",
|
|
27
|
-
"@instructure/console": "9.5.2-snapshot-
|
|
28
|
-
"@instructure/emotion": "9.5.2-snapshot-
|
|
29
|
-
"@instructure/shared-types": "9.5.2-snapshot-
|
|
30
|
-
"@instructure/ui-a11y-utils": "9.5.2-snapshot-
|
|
31
|
-
"@instructure/ui-color-utils": "9.5.2-snapshot-
|
|
32
|
-
"@instructure/ui-dom-utils": "9.5.2-snapshot-
|
|
33
|
-
"@instructure/ui-icons": "9.5.2-snapshot-
|
|
34
|
-
"@instructure/ui-prop-types": "9.5.2-snapshot-
|
|
35
|
-
"@instructure/ui-react-utils": "9.5.2-snapshot-
|
|
36
|
-
"@instructure/ui-testable": "9.5.2-snapshot-
|
|
37
|
-
"@instructure/ui-view": "9.5.2-snapshot-
|
|
27
|
+
"@instructure/console": "9.5.2-snapshot-7",
|
|
28
|
+
"@instructure/emotion": "9.5.2-snapshot-7",
|
|
29
|
+
"@instructure/shared-types": "9.5.2-snapshot-7",
|
|
30
|
+
"@instructure/ui-a11y-utils": "9.5.2-snapshot-7",
|
|
31
|
+
"@instructure/ui-color-utils": "9.5.2-snapshot-7",
|
|
32
|
+
"@instructure/ui-dom-utils": "9.5.2-snapshot-7",
|
|
33
|
+
"@instructure/ui-icons": "9.5.2-snapshot-7",
|
|
34
|
+
"@instructure/ui-prop-types": "9.5.2-snapshot-7",
|
|
35
|
+
"@instructure/ui-react-utils": "9.5.2-snapshot-7",
|
|
36
|
+
"@instructure/ui-testable": "9.5.2-snapshot-7",
|
|
37
|
+
"@instructure/ui-view": "9.5.2-snapshot-7",
|
|
38
38
|
"prop-types": "^15.8.1"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
|
-
"@instructure/ui-axe-check": "9.5.2-snapshot-
|
|
42
|
-
"@instructure/ui-babel-preset": "9.5.2-snapshot-
|
|
43
|
-
"@instructure/ui-test-utils": "9.5.2-snapshot-
|
|
44
|
-
"@instructure/ui-themes": "9.5.2-snapshot-
|
|
41
|
+
"@instructure/ui-axe-check": "9.5.2-snapshot-7",
|
|
42
|
+
"@instructure/ui-babel-preset": "9.5.2-snapshot-7",
|
|
43
|
+
"@instructure/ui-test-utils": "9.5.2-snapshot-7",
|
|
44
|
+
"@instructure/ui-themes": "9.5.2-snapshot-7",
|
|
45
45
|
"@testing-library/jest-dom": "^6.4.5",
|
|
46
46
|
"@testing-library/react": "^15.0.7",
|
|
47
47
|
"@testing-library/user-event": "^14.5.2",
|
package/src/Link/theme.ts
CHANGED
|
@@ -52,7 +52,7 @@ const generateComponentTheme = (theme: Theme): LinkTheme => {
|
|
|
52
52
|
const componentVariables: LinkTheme = {
|
|
53
53
|
fontFamily: typography?.fontFamily,
|
|
54
54
|
fontWeight: typography?.fontWeightNormal,
|
|
55
|
-
color: colors?.
|
|
55
|
+
color: colors?.contrasts?.blue4570,
|
|
56
56
|
|
|
57
57
|
textDecorationWithinText: 'underline',
|
|
58
58
|
hoverTextDecorationWithinText: 'none',
|
|
@@ -60,15 +60,15 @@ const generateComponentTheme = (theme: Theme): LinkTheme => {
|
|
|
60
60
|
hoverTextDecorationOutsideText: 'underline',
|
|
61
61
|
|
|
62
62
|
focusOutlineWidth: borders?.widthMedium,
|
|
63
|
-
focusOutlineColor: colors?.
|
|
63
|
+
focusOutlineColor: colors?.contrasts?.blue4570,
|
|
64
64
|
focusOutlineStyle: borders?.style,
|
|
65
65
|
focusOutlineBorderRadius: borders?.radiusSmall,
|
|
66
66
|
|
|
67
|
-
hoverColor: darken(colors?.
|
|
67
|
+
hoverColor: darken(colors?.contrasts?.blue5782, 10),
|
|
68
68
|
|
|
69
|
-
colorInverse: colors?.
|
|
70
|
-
focusInverseOutlineColor: colors?.
|
|
71
|
-
focusInverseIconOutlineColor: colors?.
|
|
69
|
+
colorInverse: colors?.contrasts?.grey1111,
|
|
70
|
+
focusInverseOutlineColor: colors?.contrasts?.white1010,
|
|
71
|
+
focusInverseIconOutlineColor: colors?.contrasts?.white1010,
|
|
72
72
|
|
|
73
73
|
iconSize: '1.125em', // make icon slightly larger than inherited font-size,
|
|
74
74
|
iconPlusTextMargin: spacing?.xxSmall
|