@instructure/ui-instructure 11.7.3 → 11.7.4-pr-snapshot-1781695314229

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.
Files changed (60) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/LICENSE.md +1 -0
  3. package/{lib/NutritionFacts/v1/props.js → babel.config.cjs} +12 -7
  4. package/es/AiInformation/v1/index.js +10 -5
  5. package/es/AiInformation/v2/index.js +4 -3
  6. package/es/DataPermissionLevels/v1/index.js +8 -3
  7. package/es/DataPermissionLevels/v2/index.js +2 -1
  8. package/es/NutritionFacts/v1/index.js +8 -3
  9. package/es/NutritionFacts/v2/index.js +2 -1
  10. package/es/exports/a.js +3 -3
  11. package/es/exports/b.js +3 -3
  12. package/package.json +18 -23
  13. package/src/AiInformation/v1/index.tsx +12 -5
  14. package/src/AiInformation/v2/index.tsx +4 -4
  15. package/src/DataPermissionLevels/v1/index.tsx +10 -3
  16. package/src/DataPermissionLevels/v2/index.tsx +2 -2
  17. package/src/NutritionFacts/v1/index.tsx +10 -3
  18. package/src/NutritionFacts/v2/index.tsx +2 -2
  19. package/src/exports/a.ts +3 -3
  20. package/src/exports/b.ts +3 -3
  21. package/tsconfig.build.tsbuildinfo +1 -1
  22. package/types/AiInformation/v1/index.d.ts +1 -1
  23. package/types/AiInformation/v1/index.d.ts.map +1 -1
  24. package/types/AiInformation/v2/index.d.ts +1 -1
  25. package/types/AiInformation/v2/index.d.ts.map +1 -1
  26. package/types/DataPermissionLevels/v1/index.d.ts +1 -1
  27. package/types/DataPermissionLevels/v1/index.d.ts.map +1 -1
  28. package/types/DataPermissionLevels/v2/index.d.ts +1 -1
  29. package/types/DataPermissionLevels/v2/index.d.ts.map +1 -1
  30. package/types/NutritionFacts/v1/index.d.ts +1 -1
  31. package/types/NutritionFacts/v1/index.d.ts.map +1 -1
  32. package/types/NutritionFacts/v2/index.d.ts +1 -1
  33. package/types/NutritionFacts/v2/index.d.ts.map +1 -1
  34. package/types/exports/a.d.ts +3 -3
  35. package/types/exports/a.d.ts.map +1 -1
  36. package/types/exports/b.d.ts +3 -3
  37. package/types/exports/b.d.ts.map +1 -1
  38. package/lib/AiInformation/v1/index.js +0 -196
  39. package/lib/AiInformation/v1/props.js +0 -31
  40. package/lib/AiInformation/v1/styles.js +0 -95
  41. package/lib/AiInformation/v1/theme.js +0 -59
  42. package/lib/AiInformation/v2/index.js +0 -197
  43. package/lib/AiInformation/v2/props.js +0 -31
  44. package/lib/AiInformation/v2/styles.js +0 -97
  45. package/lib/DataPermissionLevels/v1/index.js +0 -145
  46. package/lib/DataPermissionLevels/v1/props.js +0 -31
  47. package/lib/DataPermissionLevels/v1/styles.js +0 -102
  48. package/lib/DataPermissionLevels/v1/theme.js +0 -61
  49. package/lib/DataPermissionLevels/v2/index.js +0 -145
  50. package/lib/DataPermissionLevels/v2/props.js +0 -31
  51. package/lib/DataPermissionLevels/v2/styles.js +0 -103
  52. package/lib/NutritionFacts/v1/index.js +0 -154
  53. package/lib/NutritionFacts/v1/styles.js +0 -78
  54. package/lib/NutritionFacts/v1/theme.js +0 -56
  55. package/lib/NutritionFacts/v2/index.js +0 -154
  56. package/lib/NutritionFacts/v2/props.js +0 -31
  57. package/lib/NutritionFacts/v2/styles.js +0 -77
  58. package/lib/exports/a.js +0 -26
  59. package/lib/exports/b.js +0 -26
  60. package/lib/package.json +0 -1
@@ -1,4 +1,4 @@
1
- import { AiInformationProps } from './props';
1
+ import { AiInformationProps } from './props.js';
2
2
  /**
3
3
  ---
4
4
  category: components/AI Components
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/AiInformation/v1/index.tsx"],"names":[],"mappings":"AAkCA,OAAO,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAA;AAI5C;;;;GAIG;AACH,QAAA,MAAM,aAAa,GAAI,qdAoBpB,kBAAkB,qDAmIpB,CAAA;AAED,eAAe,aAAa,CAAA;AAC5B,OAAO,EAAE,aAAa,EAAE,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/AiInformation/v1/index.tsx"],"names":[],"mappings":"AAkCA,OAAO,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAA;AAI/C;;;;GAIG;AACH,QAAA,MAAM,aAAa,GAAI,qdAoBpB,kBAAkB,qDAmIpB,CAGA;AAMD,eAAe,aAAa,CAAA;AAC5B,OAAO,EAAE,aAAa,EAAE,CAAA"}
@@ -1,4 +1,4 @@
1
- import { AiInformationProps } from './props';
1
+ import { AiInformationProps } from './props.js';
2
2
  /**
3
3
  ---
4
4
  category: components/AI Components
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/AiInformation/v2/index.tsx"],"names":[],"mappings":"AAkCA,OAAO,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAA;AAG5C;;;;GAIG;AACH,QAAA,MAAM,aAAa,GAAI,oeAqBpB,kBAAkB,qDAkIpB,CAAA;AAED,eAAe,aAAa,CAAA;AAC5B,OAAO,EAAE,aAAa,EAAE,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/AiInformation/v2/index.tsx"],"names":[],"mappings":"AAkCA,OAAO,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAA;AAG/C;;;;GAIG;AACH,QAAA,MAAM,aAAa,GAAI,oeAqBpB,kBAAkB,qDAkIpB,CAAA;AAED,eAAe,aAAa,CAAA;AAC5B,OAAO,EAAE,aAAa,EAAE,CAAA"}
@@ -1,4 +1,4 @@
1
- import { DataPermissionLevelsProps } from './props';
1
+ import { DataPermissionLevelsProps } from './props.js';
2
2
  /**
3
3
  ---
4
4
  category: components/AI Components
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/DataPermissionLevels/v1/index.tsx"],"names":[],"mappings":"AA+BA,OAAO,EAAE,yBAAyB,EAAE,MAAM,SAAS,CAAA;AAInD;;;;GAIG;AACH,QAAA,MAAM,oBAAoB,GAAI,6IAU3B,yBAAyB,qDAmF3B,CAAA;AAED,eAAe,oBAAoB,CAAA;AACnC,OAAO,EAAE,oBAAoB,EAAE,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/DataPermissionLevels/v1/index.tsx"],"names":[],"mappings":"AA+BA,OAAO,EAAE,yBAAyB,EAAE,MAAM,YAAY,CAAA;AAItD;;;;GAIG;AACH,QAAA,MAAM,oBAAoB,GAAI,6IAU3B,yBAAyB,qDAmF3B,CAGA;AAMD,eAAe,oBAAoB,CAAA;AACnC,OAAO,EAAE,oBAAoB,EAAE,CAAA"}
@@ -1,4 +1,4 @@
1
- import { DataPermissionLevelsProps } from './props';
1
+ import { DataPermissionLevelsProps } from './props.js';
2
2
  /**
3
3
  ---
4
4
  category: components/AI Components
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/DataPermissionLevels/v2/index.tsx"],"names":[],"mappings":"AA+BA,OAAO,EAAE,yBAAyB,EAAE,MAAM,SAAS,CAAA;AAGnD;;;;GAIG;AACH,QAAA,MAAM,oBAAoB,GAAI,4JAW3B,yBAAyB,qDAmF3B,CAAA;AAED,eAAe,oBAAoB,CAAA;AACnC,OAAO,EAAE,oBAAoB,EAAE,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/DataPermissionLevels/v2/index.tsx"],"names":[],"mappings":"AA+BA,OAAO,EAAE,yBAAyB,EAAE,MAAM,YAAY,CAAA;AAGtD;;;;GAIG;AACH,QAAA,MAAM,oBAAoB,GAAI,4JAW3B,yBAAyB,qDAmF3B,CAAA;AAED,eAAe,oBAAoB,CAAA;AACnC,OAAO,EAAE,oBAAoB,EAAE,CAAA"}
@@ -1,4 +1,4 @@
1
- import { NutritionFactsProps } from './props';
1
+ import { NutritionFactsProps } from './props.js';
2
2
  /**
3
3
  ---
4
4
  category: components/AI Components
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/NutritionFacts/v1/index.tsx"],"names":[],"mappings":"AA+BA,OAAO,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAA;AAI7C;;;;GAIG;AACH,QAAA,MAAM,cAAc,GAAI,sHASrB,mBAAmB,qDA8FrB,CAAA;AAED,eAAe,cAAc,CAAA;AAC7B,OAAO,EAAE,cAAc,EAAE,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/NutritionFacts/v1/index.tsx"],"names":[],"mappings":"AA+BA,OAAO,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAA;AAIhD;;;;GAIG;AACH,QAAA,MAAM,cAAc,GAAI,sHASrB,mBAAmB,qDA8FrB,CAGA;AAMD,eAAe,cAAc,CAAA;AAC7B,OAAO,EAAE,cAAc,EAAE,CAAA"}
@@ -1,4 +1,4 @@
1
- import { NutritionFactsProps } from './props';
1
+ import { NutritionFactsProps } from './props.js';
2
2
  /**
3
3
  ---
4
4
  category: components/AI Components
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/NutritionFacts/v2/index.tsx"],"names":[],"mappings":"AA+BA,OAAO,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAA;AAG7C;;;;GAIG;AACH,QAAA,MAAM,cAAc,GAAI,qIAUrB,mBAAmB,qDA8FrB,CAAA;AAED,eAAe,cAAc,CAAA;AAC7B,OAAO,EAAE,cAAc,EAAE,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/NutritionFacts/v2/index.tsx"],"names":[],"mappings":"AA+BA,OAAO,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAA;AAGhD;;;;GAIG;AACH,QAAA,MAAM,cAAc,GAAI,qIAUrB,mBAAmB,qDA8FrB,CAAA;AAED,eAAe,cAAc,CAAA;AAC7B,OAAO,EAAE,cAAc,EAAE,CAAA"}
@@ -1,6 +1,6 @@
1
- export { NutritionFacts } from '../NutritionFacts/v1';
2
- export { DataPermissionLevels } from '../DataPermissionLevels/v1';
3
- export { AiInformation } from '../AiInformation/v1';
1
+ export { NutritionFacts } from '../NutritionFacts/v1/index.js';
2
+ export { DataPermissionLevels } from '../DataPermissionLevels/v1/index.js';
3
+ export { AiInformation } from '../AiInformation/v1/index.js';
4
4
  export type { NutritionFactsProps } from '../NutritionFacts/v1/props';
5
5
  export type { DataPermissionLevelsProps } from '../DataPermissionLevels/v1/props';
6
6
  export type { AiInformationProps } from '../AiInformation/v1/props';
@@ -1 +1 @@
1
- {"version":3,"file":"a.d.ts","sourceRoot":"","sources":["../../src/exports/a.ts"],"names":[],"mappings":"AAuBA,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAA;AACrD,OAAO,EAAE,oBAAoB,EAAE,MAAM,4BAA4B,CAAA;AACjE,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAA;AACnD,YAAY,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAA;AACrE,YAAY,EAAE,yBAAyB,EAAE,MAAM,kCAAkC,CAAA;AACjF,YAAY,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAA"}
1
+ {"version":3,"file":"a.d.ts","sourceRoot":"","sources":["../../src/exports/a.ts"],"names":[],"mappings":"AAuBA,OAAO,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAA;AAC9D,OAAO,EAAE,oBAAoB,EAAE,MAAM,qCAAqC,CAAA;AAC1E,OAAO,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAA;AAC5D,YAAY,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAA;AACrE,YAAY,EAAE,yBAAyB,EAAE,MAAM,kCAAkC,CAAA;AACjF,YAAY,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAA"}
@@ -1,6 +1,6 @@
1
- export { NutritionFacts } from '../NutritionFacts/v2';
2
- export { DataPermissionLevels } from '../DataPermissionLevels/v2';
3
- export { AiInformation } from '../AiInformation/v2';
1
+ export { NutritionFacts } from '../NutritionFacts/v2/index.js';
2
+ export { DataPermissionLevels } from '../DataPermissionLevels/v2/index.js';
3
+ export { AiInformation } from '../AiInformation/v2/index.js';
4
4
  export type { NutritionFactsProps } from '../NutritionFacts/v2/props';
5
5
  export type { DataPermissionLevelsProps } from '../DataPermissionLevels/v2/props';
6
6
  export type { AiInformationProps } from '../AiInformation/v2/props';
@@ -1 +1 @@
1
- {"version":3,"file":"b.d.ts","sourceRoot":"","sources":["../../src/exports/b.ts"],"names":[],"mappings":"AAuBA,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAA;AACrD,OAAO,EAAE,oBAAoB,EAAE,MAAM,4BAA4B,CAAA;AACjE,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAA;AACnD,YAAY,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAA;AACrE,YAAY,EAAE,yBAAyB,EAAE,MAAM,kCAAkC,CAAA;AACjF,YAAY,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAA"}
1
+ {"version":3,"file":"b.d.ts","sourceRoot":"","sources":["../../src/exports/b.ts"],"names":[],"mappings":"AAuBA,OAAO,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAA;AAC9D,OAAO,EAAE,oBAAoB,EAAE,MAAM,qCAAqC,CAAA;AAC1E,OAAO,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAA;AAC5D,YAAY,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAA;AACrE,YAAY,EAAE,yBAAyB,EAAE,MAAM,kCAAkC,CAAA;AACjF,YAAY,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAA"}
@@ -1,196 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
- Object.defineProperty(exports, "__esModule", {
5
- value: true
6
- });
7
- exports.default = exports.AiInformation = void 0;
8
- var _react = require("react");
9
- var _v11_ = require("@instructure/ui-popover/v11_6");
10
- var _v11_2 = require("@instructure/ui-buttons/v11_6");
11
- var _v11_3 = require("@instructure/ui-heading/v11_6");
12
- var _v11_4 = require("@instructure/ui-text/v11_6");
13
- var _v11_5 = require("@instructure/ui-link/v11_6");
14
- var _IconExternalLinkLine = require("@instructure/ui-icons/lib/generated/IconExternalLinkLine.js");
15
- var _emotion = require("@instructure/emotion");
16
- var _v = require("../../NutritionFacts/v1");
17
- var _v2 = require("../../DataPermissionLevels/v1");
18
- var _styles = _interopRequireDefault(require("./styles"));
19
- var _theme = _interopRequireDefault(require("./theme"));
20
- var _jsxRuntime = require("@emotion/react/jsx-runtime");
21
- /*
22
- * The MIT License (MIT)
23
- *
24
- * Copyright (c) 2015 - present Instructure, Inc.
25
- *
26
- * Permission is hereby granted, free of charge, to any person obtaining a copy
27
- * of this software and associated documentation files (the "Software"), to deal
28
- * in the Software without restriction, including without limitation the rights
29
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
30
- * copies of the Software, and to permit persons to whom the Software is
31
- * furnished to do so, subject to the following conditions:
32
- *
33
- * The above copyright notice and this permission notice shall be included in all
34
- * copies or substantial portions of the Software.
35
- *
36
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
37
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
38
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
39
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
40
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
41
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
42
- * SOFTWARE.
43
- */
44
-
45
- /**
46
- ---
47
- category: components/AI Components
48
- ---
49
- **/const AiInformation = ({
50
- title,
51
- data,
52
- trigger,
53
- fullscreenModals = false,
54
- dataPermissionLevelsModalLabel,
55
- dataPermissionLevelsTitle,
56
- dataPermissionLevelsData,
57
- dataPermissionLevelsCloseButtonText,
58
- dataPermissionLevelsCloseIconButtonScreenReaderLabel,
59
- dataPermissionLevelsCurrentFeature,
60
- dataPermissionLevelsCurrentFeatureText,
61
- nutritionFactsModalLabel,
62
- nutritionFactsTitle,
63
- nutritionFactsFeatureName,
64
- nutritionFactsData,
65
- nutritionFactsCloseButtonText,
66
- nutritionFactsCloseIconButtonScreenReaderLabel
67
- }) => {
68
- const [open, setOpen] = (0, _react.useState)(false);
69
- const styles = (0, _emotion.useStyle)({
70
- generateStyle: _styles.default,
71
- generateComponentTheme: _theme.default,
72
- componentId: 'AiInformation',
73
- displayName: 'AiInformation'
74
- });
75
- return (0, _jsxRuntime.jsx)("div", {
76
- children: (0, _jsxRuntime.jsx)(_v11_.Popover, {
77
- renderTrigger: trigger,
78
- isShowingContent: open,
79
- on: "click",
80
- screenReaderLabel: "Popover Dialog Example",
81
- shouldContainFocus: true,
82
- shouldReturnFocus: true,
83
- shouldCloseOnDocumentClick: true,
84
- offsetY: "1rem",
85
- onShowContent: () => setOpen(true),
86
- onHideContent: () => setOpen(false),
87
- children: (0, _jsxRuntime.jsxs)("div", {
88
- css: styles?.aiInformation,
89
- children: [(0, _jsxRuntime.jsxs)("div", {
90
- css: styles?.header,
91
- children: [(0, _jsxRuntime.jsx)(_v11_3.Heading, {
92
- level: "h2",
93
- aiVariant: "stacked",
94
- variant: "titleModule",
95
- children: title
96
- }), (0, _jsxRuntime.jsx)(_v11_2.CloseButton, {
97
- placement: "end",
98
- offset: "small",
99
- onClick: () => setOpen(false),
100
- screenReaderLabel: "Close"
101
- })]
102
- }), (0, _jsxRuntime.jsx)("div", {
103
- children: data.map(({
104
- featureName,
105
- privacyNoticeText,
106
- privacyNoticeUrl,
107
- permissionLevelText,
108
- permissionLevel,
109
- description,
110
- permissionLevelsModalTriggerText,
111
- modelNameText,
112
- modelName,
113
- nutritionFactsModalTriggerText
114
- }, index) => (0, _jsxRuntime.jsxs)("div", {
115
- children: [(0, _jsxRuntime.jsx)("div", {
116
- css: styles?.privacyNotice,
117
- children: (0, _jsxRuntime.jsx)(_v11_5.Link, {
118
- href: privacyNoticeUrl,
119
- renderIcon: (0, _jsxRuntime.jsx)(_IconExternalLinkLine.IconExternalLinkLine, {}),
120
- iconPlacement: "end",
121
- variant: "standalone",
122
- target: "_blank",
123
- children: privacyNoticeText
124
- })
125
- }), (0, _jsxRuntime.jsx)("div", {
126
- css: styles?.featureName,
127
- children: (0, _jsxRuntime.jsx)(_v11_3.Heading, {
128
- level: "h3",
129
- variant: "titleCardRegular",
130
- children: featureName
131
- })
132
- }), (0, _jsxRuntime.jsx)("div", {
133
- css: styles?.permissionLevelText,
134
- children: (0, _jsxRuntime.jsx)(_v11_3.Heading, {
135
- level: "h4",
136
- variant: "label",
137
- children: permissionLevelText
138
- })
139
- }), (0, _jsxRuntime.jsx)("div", {
140
- css: styles?.permissionLevel,
141
- children: (0, _jsxRuntime.jsxs)(_v11_4.Text, {
142
- variant: "legend",
143
- children: [" ", permissionLevel, " "]
144
- })
145
- }), (0, _jsxRuntime.jsx)("div", {
146
- css: styles?.description,
147
- children: (0, _jsxRuntime.jsxs)(_v11_4.Text, {
148
- variant: "contentSmall",
149
- children: [" ", description, " "]
150
- })
151
- }), (0, _jsxRuntime.jsx)("div", {
152
- css: styles?.permissionLevelsModalTriggerText,
153
- children: (0, _jsxRuntime.jsx)(_v2.DataPermissionLevels, {
154
- fullscreen: fullscreenModals,
155
- title: dataPermissionLevelsTitle,
156
- currentFeatureText: dataPermissionLevelsCurrentFeatureText,
157
- currentFeature: dataPermissionLevelsCurrentFeature,
158
- closeIconButtonScreenReaderLabel: dataPermissionLevelsCloseIconButtonScreenReaderLabel,
159
- closeButtonText: dataPermissionLevelsCloseButtonText,
160
- modalLabel: dataPermissionLevelsModalLabel,
161
- triggerText: permissionLevelsModalTriggerText,
162
- data: dataPermissionLevelsData
163
- })
164
- }), (0, _jsxRuntime.jsx)("div", {
165
- css: styles?.modelNameText,
166
- children: (0, _jsxRuntime.jsxs)(_v11_3.Heading, {
167
- level: "h3",
168
- variant: "label",
169
- children: [' ', modelNameText, ' ']
170
- })
171
- }), (0, _jsxRuntime.jsx)("div", {
172
- css: styles?.modelName,
173
- children: (0, _jsxRuntime.jsxs)(_v11_4.Text, {
174
- variant: "contentSmall",
175
- children: [" ", modelName, " "]
176
- })
177
- }), (0, _jsxRuntime.jsx)(_v.NutritionFacts, {
178
- fullscreen: fullscreenModals,
179
- modalLabel: nutritionFactsModalLabel,
180
- title: nutritionFactsTitle,
181
- featureName: nutritionFactsFeatureName,
182
- closeButtonText: nutritionFactsCloseButtonText,
183
- closeIconButtonScreenReaderLabel: nutritionFactsCloseIconButtonScreenReaderLabel,
184
- triggerText: nutritionFactsModalTriggerText,
185
- data: nutritionFactsData
186
- }), data.length !== index + 1 ? (0, _jsxRuntime.jsx)("div", {
187
- css: styles?.divider
188
- }) : null]
189
- }, index))
190
- })]
191
- })
192
- })
193
- });
194
- };
195
- exports.AiInformation = AiInformation;
196
- var _default = exports.default = AiInformation;
@@ -1,31 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.allowedProps = void 0;
7
- /*
8
- * The MIT License (MIT)
9
- *
10
- * Copyright (c) 2015 - present Instructure, Inc.
11
- *
12
- * Permission is hereby granted, free of charge, to any person obtaining a copy
13
- * of this software and associated documentation files (the "Software"), to deal
14
- * in the Software without restriction, including without limitation the rights
15
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
16
- * copies of the Software, and to permit persons to whom the Software is
17
- * furnished to do so, subject to the following conditions:
18
- *
19
- * The above copyright notice and this permission notice shall be included in all
20
- * copies or substantial portions of the Software.
21
- *
22
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
23
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
24
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
25
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
26
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
27
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
28
- * SOFTWARE.
29
- */
30
-
31
- const allowedProps = exports.allowedProps = ['fullscreenModals', 'title', 'data', 'trigger', 'dataPermissionLevelsModalLabel', 'dataPermissionLevelsTitle', 'dataPermissionLevelsData', 'dataPermissionLevelsCloseButtonText', 'dataPermissionLevelsCloseIconButtonScreenReaderLabel', 'dataPermissionLevelsCurrentFeatureText', 'dataPermissionLevelsCurrentFeature', 'nutritionFactsModalLabel', 'nutritionFactsTitle', 'nutritionFactsFeatureName', 'nutritionFactsData', 'nutritionFactsCloseButtonText', 'nutritionFactsCloseIconButtonScreenReaderLabel'];
@@ -1,95 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.default = void 0;
7
- /*
8
- * The MIT License (MIT)
9
- *
10
- * Copyright (c) 2015 - present Instructure, Inc.
11
- *
12
- * Permission is hereby granted, free of charge, to any person obtaining a copy
13
- * of this software and associated documentation files (the "Software"), to deal
14
- * in the Software without restriction, including without limitation the rights
15
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
16
- * copies of the Software, and to permit persons to whom the Software is
17
- * furnished to do so, subject to the following conditions:
18
- *
19
- * The above copyright notice and this permission notice shall be included in all
20
- * copies or substantial portions of the Software.
21
- *
22
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
23
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
24
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
25
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
26
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
27
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
28
- * SOFTWARE.
29
- */
30
-
31
- /**
32
- * ---
33
- * private: true
34
- * ---
35
- * Generates the style object from the theme and provided additional information
36
- * @param {Object} componentTheme The theme variable object.
37
- * @param {Object} props the props of the component, the style is applied to
38
- * @return {Object} The final style object, which will be used in the component
39
- */
40
- const generateStyle = (componentTheme, _props) => {
41
- return {
42
- aiInformation: {
43
- label: 'ai-information',
44
- width: '18.5rem',
45
- padding: componentTheme.bodyPadding,
46
- boxSizing: 'border-box'
47
- },
48
- header: {
49
- label: 'ai-information__header',
50
- marginBottom: componentTheme.headingBottomMargin
51
- },
52
- privacyNotice: {
53
- label: 'ai-information__privacyNotice',
54
- marginBottom: componentTheme.headingBottomMargin
55
- },
56
- featureName: {
57
- label: 'ai-information__feature-name',
58
- marginBottom: componentTheme.featureNameBottomMargin
59
- },
60
- permissionLevelText: {
61
- label: 'ai-information__permission-level-text',
62
- marginBottom: componentTheme.permissionLevelTextBottomMargin
63
- },
64
- permissionLevel: {
65
- label: 'ai-information__permission-level',
66
- marginBottom: componentTheme.permissionLevelBottomMargin,
67
- color: componentTheme.levelColor
68
- },
69
- description: {
70
- label: 'ai-information__description',
71
- marginBottom: componentTheme.descriptionBottomMargin
72
- },
73
- permissionLevelsModalTriggerText: {
74
- label: 'ai-information__permission-levels-modal-trigger-text',
75
- marginBottom: componentTheme.permissionLevelsModalTriggerBottomMargin
76
- },
77
- modelNameText: {
78
- label: 'ai-information__model-name-text',
79
- marginBottom: componentTheme.modelNameTextBottomMargin
80
- },
81
- modelName: {
82
- label: 'ai-information__model-name',
83
- marginBottom: componentTheme.modelNameBottomMargin
84
- },
85
- divider: {
86
- label: 'ai-information__divider',
87
- marginBottom: componentTheme.dividerMargin,
88
- marginTop: componentTheme.dividerMargin,
89
- borderTop: 'solid 1px',
90
- width: '100%',
91
- borderColor: componentTheme.dividerColor
92
- }
93
- };
94
- };
95
- var _default = exports.default = generateStyle;
@@ -1,59 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.default = void 0;
7
- /*
8
- * The MIT License (MIT)
9
- *
10
- * Copyright (c) 2015 - present Instructure, Inc.
11
- *
12
- * Permission is hereby granted, free of charge, to any person obtaining a copy
13
- * of this software and associated documentation files (the "Software"), to deal
14
- * in the Software without restriction, including without limitation the rights
15
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
16
- * copies of the Software, and to permit persons to whom the Software is
17
- * furnished to do so, subject to the following conditions:
18
- *
19
- * The above copyright notice and this permission notice shall be included in all
20
- * copies or substantial portions of the Software.
21
- *
22
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
23
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
24
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
25
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
26
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
27
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
28
- * SOFTWARE.
29
- */
30
-
31
- /**
32
- * Generates the theme object for the component from the theme and provided additional information
33
- * @param {Object} theme The actual theme object.
34
- * @return {Object} The final theme object with the overrides and component variables
35
- */
36
- const generateComponentTheme = theme => {
37
- const {
38
- colors,
39
- spacing
40
- } = theme;
41
- const componentVariables = {
42
- bodyPadding: spacing?.paddingCardLarge,
43
- headingBottomMargin: spacing?.sectionElements,
44
- featureNameBottomMargin: spacing?.moduleElements,
45
- permissionLevelTextBottomMargin: spacing?.space8,
46
- permissionLevelBottomMargin: spacing?.space8,
47
- descriptionBottomMargin: spacing?.space8,
48
- permissionLevelsModalTriggerBottomMargin: spacing?.moduleElements,
49
- modelNameTextBottomMargin: spacing?.space4,
50
- modelNameBottomMargin: spacing?.space4,
51
- dividerMargin: spacing?.moduleElements,
52
- dividerColor: colors?.ui?.surfaceDivider,
53
- levelColor: colors?.contrasts?.violet5790
54
- };
55
- return {
56
- ...componentVariables
57
- };
58
- };
59
- var _default = exports.default = generateComponentTheme;