@rancher/shell 2.0.2-rc.1 → 2.0.2
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/assets/translations/en-us.yaml +44 -30
- package/components/PromptRemove.vue +8 -3
- package/components/ResourceDetail/Masthead.vue +1 -0
- package/components/fleet/FleetClusters.vue +0 -3
- package/components/formatter/CloudCredExpired.vue +69 -0
- package/components/formatter/Date.vue +1 -1
- package/components/nav/Header.vue +9 -5
- package/components/nav/TopLevelMenu.vue +115 -51
- package/components/nav/__tests__/TopLevelMenu.test.ts +53 -27
- package/config/labels-annotations.js +2 -0
- package/detail/catalog.cattle.io.app.vue +17 -4
- package/detail/fleet.cattle.io.cluster.vue +11 -9
- package/detail/fleet.cattle.io.gitrepo.vue +1 -1
- package/edit/provisioning.cattle.io.cluster/rke2.vue +13 -0
- package/list/provisioning.cattle.io.cluster.vue +56 -5
- package/mixins/chart.js +6 -2
- package/models/catalog.cattle.io.app.js +108 -21
- package/models/cloudcredential.js +159 -2
- package/models/fleet.cattle.io.gitrepo.js +4 -13
- package/models/management.cattle.io.cluster.js +13 -2
- package/models/provisioning.cattle.io.cluster.js +37 -3
- package/package.json +1 -1
- package/pages/c/_cluster/apps/charts/install.vue +2 -1
- package/pages/c/_cluster/explorer/__tests__/index.test.ts +1 -1
- package/pages/c/_cluster/explorer/index.vue +1 -2
- package/pages/c/_cluster/fleet/index.vue +11 -5
- package/pages/c/_cluster/manager/cloudCredential/index.vue +68 -4
- package/pages/c/_cluster/uiplugins/index.vue +4 -2
- package/pages/home.vue +1 -0
- package/scripts/extension/bundle +1 -1
- package/scripts/publish-shell.sh +3 -4
- package/scripts/typegen.sh +26 -23
- package/types/shell/index.d.ts +4595 -0
- package/utils/cluster.js +1 -1
- package/utils/string.js +9 -0
- package/utils/v-sphere.ts +251 -0
- package/shell/types/shell/index.d.ts +0 -2
|
@@ -153,7 +153,8 @@ export default {
|
|
|
153
153
|
},
|
|
154
154
|
|
|
155
155
|
showAddReposBanner() {
|
|
156
|
-
|
|
156
|
+
// because of https://github.com/rancher/rancher/pull/45894 we need to consider other start values
|
|
157
|
+
const hasExtensionReposBannerSetting = this.addExtensionReposBannerSetting?.value === 'true' || this.addExtensionReposBannerSetting?.value === '' || this.addExtensionReposBannerSetting?.value === undefined;
|
|
157
158
|
const uiPluginsRepoNotFound = isRancherPrime() && !this.repos?.find((r) => r.urlDisplay === UI_PLUGINS_REPO_URL);
|
|
158
159
|
const uiPluginsPartnersRepoNotFound = !this.repos?.find((r) => r.urlDisplay === UI_PLUGINS_PARTNERS_REPO_URL);
|
|
159
160
|
|
|
@@ -623,7 +624,8 @@ export default {
|
|
|
623
624
|
},
|
|
624
625
|
|
|
625
626
|
updateAddReposSetting() {
|
|
626
|
-
|
|
627
|
+
// because of https://github.com/rancher/rancher/pull/45894 we need to consider other start values
|
|
628
|
+
if (this.addExtensionReposBannerSetting?.value === 'true' || this.addExtensionReposBannerSetting?.value === '' || this.addExtensionReposBannerSetting?.value === undefined) {
|
|
627
629
|
this.addExtensionReposBannerSetting.value = 'false';
|
|
628
630
|
this.addExtensionReposBannerSetting.save();
|
|
629
631
|
}
|
package/pages/home.vue
CHANGED
package/scripts/extension/bundle
CHANGED
|
@@ -43,7 +43,7 @@ for d in ${BASE_DIR}/dist-pkg/*; do
|
|
|
43
43
|
mkdir plugin && mv ./${pkg}/* ./plugin
|
|
44
44
|
rm -rf ./${pkg}/* && mv ./plugin ./${pkg}
|
|
45
45
|
|
|
46
|
-
find ${pkg} -type f
|
|
46
|
+
find ${pkg} -type f | sed "s|^${pkg}/||" | sort > ./${pkg}/files.txt
|
|
47
47
|
popd > /dev/null
|
|
48
48
|
|
|
49
49
|
cp -R ${BASE_DIR}/dist-pkg/${pkg} ${TMP}/container/plugin
|
package/scripts/publish-shell.sh
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
#!/usr/bin/env bash
|
|
2
2
|
|
|
3
|
+
set -eo pipefail
|
|
4
|
+
|
|
3
5
|
SCRIPT_DIR="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" &>/dev/null && pwd)"
|
|
4
|
-
BASE_DIR="$(
|
|
5
|
-
cd $SCRIPT_DIR && cd ../.. &
|
|
6
|
-
pwd
|
|
7
|
-
)"
|
|
6
|
+
BASE_DIR="$(cd $SCRIPT_DIR && cd ../.. && pwd)"
|
|
8
7
|
SHELL_DIR=$BASE_DIR/shell/
|
|
9
8
|
CREATORS_DIR=$BASE_DIR/creators/extension
|
|
10
9
|
FORCE_PUBLISH_TO_NPM="false"
|
package/scripts/typegen.sh
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env bash
|
|
2
2
|
|
|
3
3
|
SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
|
|
4
|
-
BASE_DIR="$(
|
|
4
|
+
BASE_DIR="$(git rev-parse --show-toplevel)"
|
|
5
5
|
SHELL_DIR=$BASE_DIR/shell
|
|
6
6
|
|
|
7
7
|
echo "Generating typescript definitions"
|
|
@@ -12,37 +12,40 @@ mkdir -p ${SHELL_DIR}/tmp
|
|
|
12
12
|
echo "Generating ..."
|
|
13
13
|
|
|
14
14
|
# utils
|
|
15
|
-
${BASE_DIR}/node_modules/.bin/tsc
|
|
16
|
-
${BASE_DIR}/node_modules/.bin/tsc
|
|
17
|
-
${BASE_DIR}/node_modules/.bin/tsc
|
|
15
|
+
${BASE_DIR}/node_modules/.bin/tsc ${SHELL_DIR}/utils/*.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/utils > /dev/null
|
|
16
|
+
${BASE_DIR}/node_modules/.bin/tsc ${SHELL_DIR}/utils/validators/*.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/utils/validators > /dev/null
|
|
17
|
+
${BASE_DIR}/node_modules/.bin/tsc ${SHELL_DIR}/utils/crypto/*.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/utils/crypto > /dev/null
|
|
18
18
|
|
|
19
19
|
# config
|
|
20
|
-
${BASE_DIR}/node_modules/.bin/tsc
|
|
21
|
-
${BASE_DIR}/node_modules/.bin/tsc
|
|
22
|
-
${BASE_DIR}/node_modules/.bin/tsc
|
|
23
|
-
${BASE_DIR}/node_modules/.bin/tsc
|
|
20
|
+
${BASE_DIR}/node_modules/.bin/tsc ${SHELL_DIR}/config/query-params.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/config > /dev/null
|
|
21
|
+
${BASE_DIR}/node_modules/.bin/tsc ${SHELL_DIR}/config/table-headers.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/config > /dev/null
|
|
22
|
+
${BASE_DIR}/node_modules/.bin/tsc ${SHELL_DIR}/config/types.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/config > /dev/null
|
|
23
|
+
${BASE_DIR}/node_modules/.bin/tsc ${SHELL_DIR}/config/labels-annotations.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/config > /dev/null
|
|
24
24
|
|
|
25
|
-
# store
|
|
26
|
-
${BASE_DIR}/node_modules/.bin/tsc
|
|
27
|
-
${BASE_DIR}/node_modules/.bin/tsc
|
|
25
|
+
# # store
|
|
26
|
+
${BASE_DIR}/node_modules/.bin/tsc ${SHELL_DIR}/store/features.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/store > /dev/null
|
|
27
|
+
${BASE_DIR}/node_modules/.bin/tsc ${SHELL_DIR}/store/prefs.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/store > /dev/null
|
|
28
28
|
|
|
29
|
-
# plugins
|
|
30
|
-
${BASE_DIR}/node_modules/.bin/tsc
|
|
31
|
-
${BASE_DIR}/node_modules/.bin/tsc
|
|
32
|
-
${BASE_DIR}/node_modules/.bin/tsc
|
|
33
|
-
${BASE_DIR}/node_modules/.bin/tsc
|
|
29
|
+
# # plugins
|
|
30
|
+
${BASE_DIR}/node_modules/.bin/tsc ${SHELL_DIR}/plugins/dashboard-store/normalize.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/plugins/dashboard-store/ > /dev/null
|
|
31
|
+
${BASE_DIR}/node_modules/.bin/tsc ${SHELL_DIR}/plugins/dashboard-store/resource-class.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/plugins/dashboard-store/ > /dev/null
|
|
32
|
+
${BASE_DIR}/node_modules/.bin/tsc ${SHELL_DIR}/plugins/dashboard-store/classify.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/plugins/dashboard-store/ > /dev/null
|
|
33
|
+
${BASE_DIR}/node_modules/.bin/tsc ${SHELL_DIR}/plugins/dashboard-store/actions.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/plugins/dashboard-store/ > /dev/null
|
|
34
34
|
|
|
35
|
-
# mixins
|
|
36
|
-
${BASE_DIR}/node_modules/.bin/tsc
|
|
35
|
+
# # mixins
|
|
36
|
+
${BASE_DIR}/node_modules/.bin/tsc ${SHELL_DIR}/mixins/create-edit-view/index.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/mixins/create-edit-view > /dev/null
|
|
37
37
|
|
|
38
|
-
# models
|
|
39
|
-
${BASE_DIR}/node_modules/.bin/tsc
|
|
40
|
-
${BASE_DIR}/node_modules/.bin/tsc
|
|
38
|
+
# # models
|
|
39
|
+
${BASE_DIR}/node_modules/.bin/tsc ${SHELL_DIR}/models/namespace.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/models/ > /dev/null
|
|
40
|
+
${BASE_DIR}/node_modules/.bin/tsc ${SHELL_DIR}/models/networking.k8s.io.ingress.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/models/ > /dev/null
|
|
41
41
|
|
|
42
|
-
#./node_modules/.bin/tsc
|
|
42
|
+
#./node_modules/.bin/tsc ${SHELL_DIR}/plugins/dashboard-store/*.js --declaration --allowJs --emitDeclarationOnly --outDir ${SHELL_DIR}/tmp/plugins/dashboard-store
|
|
43
43
|
|
|
44
44
|
# Go through all of the folders and combine by wrapping with 'declare module'
|
|
45
45
|
|
|
46
|
+
echo "Contents of ${SHELL_DIR}/tmp after tsc commands:"
|
|
47
|
+
find ${SHELL_DIR}/tmp
|
|
48
|
+
|
|
46
49
|
echo "Combining type definitions ..."
|
|
47
50
|
|
|
48
51
|
DEST=${SHELL_DIR}/types/shell
|
|
@@ -90,4 +93,4 @@ function processDir() {
|
|
|
90
93
|
|
|
91
94
|
processDir ${SHELL_DIR}/tmp @shell
|
|
92
95
|
|
|
93
|
-
rm -rf ${SHELL_DIR}/tmp
|
|
96
|
+
rm -rf ${SHELL_DIR}/tmp
|