Skip to content

Commit

Permalink
feat: option for configuring is_visible in globalConfig.json
Browse files Browse the repository at this point in the history
  • Loading branch information
Benni0 committed Sep 9, 2024
1 parent 17d29d0 commit 4075cf4
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/metadata.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,4 @@ Metadata contains general information about add-on build.
| defaultView | string | Define which view should be loaded on TA load. One of `"inputs"`, `"configuration"`, `"dashboard"` or `"search"`. Default `configuration`. |
| [os-dependentLibraries](./advanced/os-dependent_libraries.md) | array | This feature allows you to download and unpack libraries with appropriate binaries for the indicated operating system during the build process. |
| supported_themes | array | This feature is allows you provide the themes supported by your add-on. Supported values: `light`, `dark`. No default. |
| isVisible | boolean | This option allows you to create apps which are not visible by default by setting isVisible=false. |
2 changes: 2 additions & 0 deletions splunk_add_on_ucc_framework/commands/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -642,6 +642,8 @@ def generate(
supported_themes = ""
if global_config:
should_be_visible = True
if global_config.meta.get("isVisible") is not None:
should_be_visible = global_config.meta.get("isVisible")
if global_config.meta.get("checkForUpdates") is False:
check_for_updates = "false"
if global_config.meta.get("supportedThemes") is not None:
Expand Down
5 changes: 5 additions & 0 deletions splunk_add_on_ucc_framework/schema/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -1740,6 +1740,11 @@
"default": true,
"description": "Ability to configure app.conf->package.check_for_updates from globalConfig file."
},
"isVisible": {
"type": "boolean",
"default": true,
"description": "Ability to configure app.conf->ui.is_visible from globalConfig file."
},
"defaultView": {
"type": "string",
"description": "Define which view should be loaded on TA load.",
Expand Down

0 comments on commit 4075cf4

Please sign in to comment.