@backstage/plugin-techdocs 0.0.0-nightly-20240930023420 → 0.0.0-nightly-20241002023110

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 CHANGED
@@ -1,26 +1,51 @@
1
1
  # @backstage/plugin-techdocs
2
2
 
3
- ## 0.0.0-nightly-20240930023420
3
+ ## 0.0.0-nightly-20241002023110
4
4
 
5
5
  ### Patch Changes
6
6
 
7
+ - e969dc7: Move `@types/react` to a peer dependency.
7
8
  - a77cb40: Make `emptyState` input optional on `entity-content:techdocs` extension so that
8
9
  the default empty state extension works correctly.
10
+ - e918061: Add support for mkdocs material palette conditional hashes.
11
+ - Updated dependencies
12
+ - @backstage/core-components@0.0.0-nightly-20241002023110
13
+ - @backstage/frontend-plugin-api@0.0.0-nightly-20241002023110
14
+ - @backstage/integration-react@0.0.0-nightly-20241002023110
15
+ - @backstage/core-compat-api@0.0.0-nightly-20241002023110
16
+ - @backstage/core-plugin-api@0.0.0-nightly-20241002023110
17
+ - @backstage/plugin-techdocs-react@0.0.0-nightly-20241002023110
18
+ - @backstage/plugin-catalog-react@0.0.0-nightly-20241002023110
19
+ - @backstage/plugin-search-react@0.0.0-nightly-20241002023110
20
+ - @backstage/plugin-auth-react@0.0.0-nightly-20241002023110
21
+ - @backstage/theme@0.0.0-nightly-20241002023110
22
+ - @backstage/integration@0.0.0-nightly-20241002023110
23
+ - @backstage/catalog-model@1.7.0
24
+ - @backstage/config@1.2.0
25
+ - @backstage/errors@1.2.4
26
+ - @backstage/plugin-search-common@1.2.14
27
+ - @backstage/plugin-techdocs-common@0.1.0
28
+
29
+ ## 1.10.11-next.1
30
+
31
+ ### Patch Changes
32
+
33
+ - e969dc7: Move `@types/react` to a peer dependency.
9
34
  - Updated dependencies
10
- - @backstage/core-components@0.0.0-nightly-20240930023420
11
- - @backstage/frontend-plugin-api@0.0.0-nightly-20240930023420
12
- - @backstage/integration-react@0.0.0-nightly-20240930023420
13
- - @backstage/plugin-catalog-react@0.0.0-nightly-20240930023420
14
- - @backstage/core-compat-api@0.0.0-nightly-20240930023420
15
- - @backstage/core-plugin-api@0.0.0-nightly-20240930023420
16
- - @backstage/plugin-auth-react@0.0.0-nightly-20240930023420
17
- - @backstage/plugin-search-react@0.0.0-nightly-20240930023420
18
- - @backstage/plugin-techdocs-react@0.0.0-nightly-20240930023420
35
+ - @backstage/core-components@0.15.1-next.1
36
+ - @backstage/frontend-plugin-api@0.9.0-next.1
37
+ - @backstage/integration-react@1.2.0-next.1
38
+ - @backstage/core-compat-api@0.3.1-next.1
39
+ - @backstage/core-plugin-api@1.10.0-next.1
40
+ - @backstage/plugin-techdocs-react@1.2.9-next.1
41
+ - @backstage/plugin-catalog-react@1.14.0-next.1
42
+ - @backstage/plugin-search-react@1.8.1-next.1
43
+ - @backstage/plugin-auth-react@0.1.7-next.1
44
+ - @backstage/theme@0.5.8-next.0
45
+ - @backstage/integration@1.15.1-next.0
19
46
  - @backstage/catalog-model@1.7.0
20
47
  - @backstage/config@1.2.0
21
48
  - @backstage/errors@1.2.4
22
- - @backstage/integration@1.15.0
23
- - @backstage/theme@0.5.7
24
49
  - @backstage/plugin-search-common@1.2.14
25
50
  - @backstage/plugin-techdocs-common@0.1.0
26
51
 
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@backstage/plugin-techdocs__alpha",
3
- "version": "0.0.0-nightly-20240930023420",
3
+ "version": "0.0.0-nightly-20241002023110",
4
4
  "main": "../dist/alpha.esm.js",
5
5
  "module": "../dist/alpha.esm.js",
6
6
  "types": "../dist/alpha.d.ts"
@@ -0,0 +1,19 @@
1
+ const themeHashes = {
2
+ dark: ["#only-light", "#gh-light-mode-only"],
3
+ light: ["#only-dark", "#gh-dark-mode-only"]
4
+ };
5
+ var palette = ({ theme }) => `
6
+ /*================== Palette ==================*/
7
+ /*
8
+ When color palette toggle is enabled in material theme for Mkdocs, there is a possibility to show conditionally
9
+ images by adding #only-dark or #only-light to resource hash. Backstage doesn't use mkdocs color palette mechanism,
10
+ so there is a need to add css rules from palette*.css manually.
11
+ */
12
+
13
+ ${themeHashes[theme.palette.type].map((hash) => `img[src$="${hash}"]`).join(", ")} {
14
+ display: none;
15
+ }
16
+ `;
17
+
18
+ export { palette as default };
19
+ //# sourceMappingURL=palette.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"palette.esm.js","sources":["../../../../../src/reader/transformers/styles/rules/palette.ts"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { RuleOptions } from './types';\nimport { Theme } from '@material-ui/core/styles';\n\nconst themeHashes: Record<Theme['palette']['type'], ReadonlyArray<string>> = {\n dark: ['#only-light', '#gh-light-mode-only'],\n light: ['#only-dark', '#gh-dark-mode-only'],\n};\n\nexport default ({ theme }: RuleOptions) => `\n/*================== Palette ==================*/\n/*\n When color palette toggle is enabled in material theme for Mkdocs, there is a possibility to show conditionally \n images by adding #only-dark or #only-light to resource hash. Backstage doesn't use mkdocs color palette mechanism,\n so there is a need to add css rules from palette*.css manually.\n*/\n\n${themeHashes[theme.palette.type]\n .map(hash => `img[src$=\"${hash}\"]`)\n .join(', ')} {\n display: none;\n}\n`;\n"],"names":[],"mappings":"AAmBA,MAAM,WAAuE,GAAA;AAAA,EAC3E,IAAA,EAAM,CAAC,aAAA,EAAe,qBAAqB,CAAA;AAAA,EAC3C,KAAA,EAAO,CAAC,YAAA,EAAc,oBAAoB,CAAA;AAC5C,CAAA,CAAA;AAEA,cAAe,CAAC,EAAE,KAAA,EAAyB,KAAA,CAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAQzC,WAAY,CAAA,KAAA,CAAM,OAAQ,CAAA,IAAI,CAC7B,CAAA,GAAA,CAAI,CAAQ,IAAA,KAAA,CAAA,UAAA,EAAa,IAAI,CAAA,EAAA,CAAI,CACjC,CAAA,IAAA,CAAK,IAAI,CAAC,CAAA;AAAA;AAAA;AAAA,CAAA;;;;"}
@@ -4,6 +4,7 @@ import layout from './layout.esm.js';
4
4
  import typeset from './typeset.esm.js';
5
5
  import animations from './animations.esm.js';
6
6
  import extensions from './extensions.esm.js';
7
+ import palette from './palette.esm.js';
7
8
 
8
9
  const rules = [
9
10
  variables,
@@ -11,7 +12,8 @@ const rules = [
11
12
  layout,
12
13
  typeset,
13
14
  animations,
14
- extensions
15
+ extensions,
16
+ palette
15
17
  ];
16
18
 
17
19
  export { rules };
@@ -1 +1 @@
1
- {"version":3,"file":"rules.esm.js","sources":["../../../../../src/reader/transformers/styles/rules/rules.ts"],"sourcesContent":["/*\n * Copyright 2022 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { default as variables } from './variables';\nimport { default as reset } from './reset';\nimport { default as layout } from './layout';\nimport { default as typeset } from './typeset';\nimport { default as animations } from './animations';\nimport { default as extensions } from './extensions';\n\n/**\n * A list of style rules that will be applied to an element in the order they were added.\n *\n * @remarks\n * The order of items is important, which means that a rule can override any other rule previously added to the list,\n * i.e. the rules will be applied from the first added to the last added.\n */\nexport const rules = [\n variables,\n reset,\n layout,\n typeset,\n animations,\n extensions,\n];\n"],"names":[],"mappings":";;;;;;;AA8BO,MAAM,KAAQ,GAAA;AAAA,EACnB,SAAA;AAAA,EACA,KAAA;AAAA,EACA,MAAA;AAAA,EACA,OAAA;AAAA,EACA,UAAA;AAAA,EACA,UAAA;AACF;;;;"}
1
+ {"version":3,"file":"rules.esm.js","sources":["../../../../../src/reader/transformers/styles/rules/rules.ts"],"sourcesContent":["/*\n * Copyright 2022 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { default as variables } from './variables';\nimport { default as reset } from './reset';\nimport { default as layout } from './layout';\nimport { default as typeset } from './typeset';\nimport { default as animations } from './animations';\nimport { default as extensions } from './extensions';\nimport palette from './palette';\n\n/**\n * A list of style rules that will be applied to an element in the order they were added.\n *\n * @remarks\n * The order of items is important, which means that a rule can override any other rule previously added to the list,\n * i.e. the rules will be applied from the first added to the last added.\n */\nexport const rules = [\n variables,\n reset,\n layout,\n typeset,\n animations,\n extensions,\n palette,\n];\n"],"names":[],"mappings":";;;;;;;;AA+BO,MAAM,KAAQ,GAAA;AAAA,EACnB,SAAA;AAAA,EACA,KAAA;AAAA,EACA,MAAA;AAAA,EACA,OAAA;AAAA,EACA,UAAA;AAAA,EACA,UAAA;AAAA,EACA,OAAA;AACF;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@backstage/plugin-techdocs",
3
- "version": "0.0.0-nightly-20240930023420",
3
+ "version": "0.0.0-nightly-20241002023110",
4
4
  "description": "The Backstage plugin that renders technical documentation for your components",
5
5
  "backstage": {
6
6
  "role": "frontend-plugin",
@@ -61,26 +61,25 @@
61
61
  "dependencies": {
62
62
  "@backstage/catalog-model": "1.7.0",
63
63
  "@backstage/config": "1.2.0",
64
- "@backstage/core-compat-api": "0.0.0-nightly-20240930023420",
65
- "@backstage/core-components": "0.0.0-nightly-20240930023420",
66
- "@backstage/core-plugin-api": "0.0.0-nightly-20240930023420",
64
+ "@backstage/core-compat-api": "0.0.0-nightly-20241002023110",
65
+ "@backstage/core-components": "0.0.0-nightly-20241002023110",
66
+ "@backstage/core-plugin-api": "0.0.0-nightly-20241002023110",
67
67
  "@backstage/errors": "1.2.4",
68
- "@backstage/frontend-plugin-api": "0.0.0-nightly-20240930023420",
69
- "@backstage/integration": "1.15.0",
70
- "@backstage/integration-react": "0.0.0-nightly-20240930023420",
71
- "@backstage/plugin-auth-react": "0.0.0-nightly-20240930023420",
72
- "@backstage/plugin-catalog-react": "0.0.0-nightly-20240930023420",
68
+ "@backstage/frontend-plugin-api": "0.0.0-nightly-20241002023110",
69
+ "@backstage/integration": "0.0.0-nightly-20241002023110",
70
+ "@backstage/integration-react": "0.0.0-nightly-20241002023110",
71
+ "@backstage/plugin-auth-react": "0.0.0-nightly-20241002023110",
72
+ "@backstage/plugin-catalog-react": "0.0.0-nightly-20241002023110",
73
73
  "@backstage/plugin-search-common": "1.2.14",
74
- "@backstage/plugin-search-react": "0.0.0-nightly-20240930023420",
74
+ "@backstage/plugin-search-react": "0.0.0-nightly-20241002023110",
75
75
  "@backstage/plugin-techdocs-common": "0.1.0",
76
- "@backstage/plugin-techdocs-react": "0.0.0-nightly-20240930023420",
77
- "@backstage/theme": "0.5.7",
76
+ "@backstage/plugin-techdocs-react": "0.0.0-nightly-20241002023110",
77
+ "@backstage/theme": "0.0.0-nightly-20241002023110",
78
78
  "@material-ui/core": "^4.12.2",
79
79
  "@material-ui/icons": "^4.9.1",
80
80
  "@material-ui/lab": "4.0.0-alpha.61",
81
81
  "@material-ui/styles": "^4.10.0",
82
82
  "@microsoft/fetch-event-source": "^2.0.1",
83
- "@types/react": "^16.13.1 || ^17.0.0 || ^18.0.0",
84
83
  "dompurify": "^3.0.0",
85
84
  "git-url-parse": "^14.0.0",
86
85
  "jss": "~10.10.0",
@@ -89,23 +88,33 @@
89
88
  "react-use": "^17.2.4"
90
89
  },
91
90
  "devDependencies": {
92
- "@backstage/cli": "0.0.0-nightly-20240930023420",
93
- "@backstage/core-app-api": "0.0.0-nightly-20240930023420",
94
- "@backstage/dev-utils": "0.0.0-nightly-20240930023420",
95
- "@backstage/plugin-techdocs-module-addons-contrib": "0.0.0-nightly-20240930023420",
96
- "@backstage/test-utils": "0.0.0-nightly-20240930023420",
91
+ "@backstage/cli": "0.0.0-nightly-20241002023110",
92
+ "@backstage/core-app-api": "0.0.0-nightly-20241002023110",
93
+ "@backstage/dev-utils": "0.0.0-nightly-20241002023110",
94
+ "@backstage/plugin-techdocs-module-addons-contrib": "0.0.0-nightly-20241002023110",
95
+ "@backstage/test-utils": "0.0.0-nightly-20241002023110",
97
96
  "@testing-library/dom": "^10.0.0",
98
97
  "@testing-library/jest-dom": "^6.0.0",
99
98
  "@testing-library/react": "^16.0.0",
100
99
  "@testing-library/user-event": "^14.0.0",
101
100
  "@types/dompurify": "^3.0.0",
102
- "canvas": "^2.10.2"
101
+ "@types/react": "^18.0.0",
102
+ "canvas": "^2.10.2",
103
+ "react": "^18.0.2",
104
+ "react-dom": "^18.0.2",
105
+ "react-router-dom": "^6.3.0"
103
106
  },
104
107
  "peerDependencies": {
108
+ "@types/react": "^16.13.1 || ^17.0.0 || ^18.0.0",
105
109
  "react": "^16.13.1 || ^17.0.0 || ^18.0.0",
106
110
  "react-dom": "^16.13.1 || ^17.0.0 || ^18.0.0",
107
111
  "react-router-dom": "6.0.0-beta.0 || ^6.3.0"
108
112
  },
113
+ "peerDependenciesMeta": {
114
+ "@types/react": {
115
+ "optional": true
116
+ }
117
+ },
109
118
  "configSchema": "config.d.ts",
110
119
  "module": "./dist/index.esm.js"
111
120
  }