mirror of
https://github.com/LizardByte/Sunshine.git
synced 2025-08-10 00:52:16 +00:00
fix(checkbox): inverse global prep values for apps (#3547)
Some checks are pending
CI / GitHub Env Debug (push) Waiting to run
CI / Setup Release (push) Waiting to run
CI / Setup Flatpak Matrix (push) Waiting to run
CI / Linux Flatpak (push) Blocked by required conditions
CI / Linux ${{ matrix.type }} (--appimage-build, 22.04, AppImage) (push) Blocked by required conditions
CI / Homebrew (${{ matrix.os_name }}-${{ matrix.os_version }}${{ matrix.release == true && ' (Release)' || '' }}) (macos, 13) (push) Blocked by required conditions
CI / Homebrew (${{ matrix.os_name }}-${{ matrix.os_version }}${{ matrix.release == true && ' (Release)' || '' }}) (macos, 14) (push) Blocked by required conditions
CI / Homebrew (${{ matrix.os_name }}-${{ matrix.os_version }}${{ matrix.release == true && ' (Release)' || '' }}) (ubuntu, latest) (push) Blocked by required conditions
CI / Homebrew (${{ matrix.os_name }}-${{ matrix.os_version }}${{ matrix.release == true && ' (Release)' || '' }}) (ubuntu, latest, true) (push) Blocked by required conditions
CI / Windows (push) Blocked by required conditions
CI Docker / Check Dockerfiles (push) Waiting to run
CI Docker / Setup Release (push) Blocked by required conditions
CI Docker / Docker${{ matrix.tag }} (push) Blocked by required conditions
CodeQL / Get language matrix (push) Waiting to run
CodeQL / Analyze (${{ matrix.name }}) (push) Blocked by required conditions
Build GH-Pages / prep (push) Waiting to run
Build GH-Pages / call-jekyll-build (push) Blocked by required conditions
Some checks are pending
CI / GitHub Env Debug (push) Waiting to run
CI / Setup Release (push) Waiting to run
CI / Setup Flatpak Matrix (push) Waiting to run
CI / Linux Flatpak (push) Blocked by required conditions
CI / Linux ${{ matrix.type }} (--appimage-build, 22.04, AppImage) (push) Blocked by required conditions
CI / Homebrew (${{ matrix.os_name }}-${{ matrix.os_version }}${{ matrix.release == true && ' (Release)' || '' }}) (macos, 13) (push) Blocked by required conditions
CI / Homebrew (${{ matrix.os_name }}-${{ matrix.os_version }}${{ matrix.release == true && ' (Release)' || '' }}) (macos, 14) (push) Blocked by required conditions
CI / Homebrew (${{ matrix.os_name }}-${{ matrix.os_version }}${{ matrix.release == true && ' (Release)' || '' }}) (ubuntu, latest) (push) Blocked by required conditions
CI / Homebrew (${{ matrix.os_name }}-${{ matrix.os_version }}${{ matrix.release == true && ' (Release)' || '' }}) (ubuntu, latest, true) (push) Blocked by required conditions
CI / Windows (push) Blocked by required conditions
CI Docker / Check Dockerfiles (push) Waiting to run
CI Docker / Setup Release (push) Blocked by required conditions
CI Docker / Docker${{ matrix.tag }} (push) Blocked by required conditions
CodeQL / Get language matrix (push) Waiting to run
CodeQL / Analyze (${{ matrix.name }}) (push) Blocked by required conditions
Build GH-Pages / prep (push) Waiting to run
Build GH-Pages / call-jekyll-build (push) Blocked by required conditions
This commit is contained in:
@@ -22,6 +22,10 @@ const props = defineProps({
|
||||
type: String,
|
||||
default: "missing-prefix"
|
||||
},
|
||||
inverseValues: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
default: {
|
||||
type: undefined,
|
||||
default: null,
|
||||
@@ -79,7 +83,9 @@ const checkboxValues = (() => {
|
||||
return ["true", "false"];
|
||||
})();
|
||||
|
||||
return { truthy: mappedValues[0], falsy: mappedValues[1] };
|
||||
const truthyIndex = props.inverseValues ? 1 : 0;
|
||||
const falsyIndex = props.inverseValues ? 0 : 1;
|
||||
return { truthy: mappedValues[truthyIndex], falsy: mappedValues[falsyIndex] };
|
||||
})();
|
||||
const parsedDefaultPropValue = (() => {
|
||||
const boolValues = mapToBoolRepresentation(props.default);
|
||||
|
||||
@@ -122,6 +122,7 @@
|
||||
desc="apps.global_prep_desc"
|
||||
v-model="editForm['exclude-global-prep-cmd']"
|
||||
default="true"
|
||||
inverse-values
|
||||
></Checkbox>
|
||||
<div class="mb-3">
|
||||
<label for="appName" class="form-label">{{ $t('apps.cmd_prep_name') }}</label>
|
||||
|
||||
Reference in New Issue
Block a user