@gitlab/ui 66.37.0 → 67.1.0
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 +21 -0
- package/dist/directives/safe_html/constants.js +2 -1
- package/dist/directives/safe_html/safe_html.js +3 -2
- package/dist/tokens/css/tokens.css +1 -1
- package/dist/tokens/css/tokens.dark.css +1 -1
- package/dist/tokens/js/tokens.dark.js +1 -1
- package/dist/tokens/js/tokens.js +1 -1
- package/dist/tokens/scss/_tokens.dark.scss +1 -1
- package/dist/tokens/scss/_tokens.scss +1 -1
- package/dist/utility_classes.css +1 -1
- package/dist/utility_classes.css.map +1 -1
- package/package.json +1 -1
- package/src/directives/safe_html/constants.js +2 -0
- package/src/directives/safe_html/safe_html.js +3 -2
- package/src/directives/safe_html/safe_html.spec.js +15 -0
- package/src/scss/utilities.scss +8 -0
- package/src/scss/utility-mixins/color.scss +4 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,24 @@
|
|
|
1
|
+
# [67.1.0](https://gitlab.com/gitlab-org/gitlab-ui/compare/v67.0.0...v67.1.0) (2023-10-27)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Features
|
|
5
|
+
|
|
6
|
+
* **color:** Add utility classes used in top header ([6d3e4cf](https://gitlab.com/gitlab-org/gitlab-ui/commit/6d3e4cfab9f78dfbfd81b1678fde6d0733fb769e))
|
|
7
|
+
|
|
8
|
+
# [67.0.0](https://gitlab.com/gitlab-org/gitlab-ui/compare/v66.37.0...v67.0.0) (2023-10-27)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Features
|
|
12
|
+
|
|
13
|
+
* **SafeHtml:** disallow potentially dangerous tags ([25926ab](https://gitlab.com/gitlab-org/gitlab-ui/commit/25926ab418ffbbbe657a6a1485d01c13368e2a67))
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
### BREAKING CHANGES
|
|
17
|
+
|
|
18
|
+
* **SafeHtml:** This change improves safe-html defense
|
|
19
|
+
by adding style, mystlye and form tags to the forbidden
|
|
20
|
+
list.
|
|
21
|
+
|
|
1
22
|
# [66.37.0](https://gitlab.com/gitlab-org/gitlab-ui/compare/v66.36.1...v66.37.0) (2023-10-25)
|
|
2
23
|
|
|
3
24
|
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
// See https://gitlab.com/gitlab-org/gitlab-ui/-/issues/1421#note_617098438
|
|
2
2
|
// for more details
|
|
3
3
|
const forbiddenDataAttrs = ['data-remote', 'data-url', 'data-type', 'data-method', 'data-disable-with', 'data-disabled', 'data-disable', 'data-turbo'];
|
|
4
|
+
const forbiddenTags = ['style', 'mstyle', 'form'];
|
|
4
5
|
|
|
5
|
-
export { forbiddenDataAttrs };
|
|
6
|
+
export { forbiddenDataAttrs, forbiddenTags };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import DOMPurify from 'dompurify';
|
|
2
|
-
import { forbiddenDataAttrs } from './constants';
|
|
2
|
+
import { forbiddenDataAttrs, forbiddenTags } from './constants';
|
|
3
3
|
|
|
4
4
|
const {
|
|
5
5
|
sanitize
|
|
@@ -13,7 +13,8 @@ const {
|
|
|
13
13
|
const DEFAULT_CONFIG = {
|
|
14
14
|
RETURN_DOM_FRAGMENT: true,
|
|
15
15
|
ALLOW_UNKNOWN_PROTOCOLS: true,
|
|
16
|
-
FORBID_ATTR:
|
|
16
|
+
FORBID_ATTR: forbiddenDataAttrs,
|
|
17
|
+
FORBID_TAGS: forbiddenTags
|
|
17
18
|
};
|
|
18
19
|
const transform = (el, binding) => {
|
|
19
20
|
if (binding.oldValue !== binding.value) {
|
package/dist/tokens/js/tokens.js
CHANGED