From cb88eabb86d0cc51c1eb6ffa7b201a38675aeb9d Mon Sep 17 00:00:00 2001 From: "R.J. (Steinert) Corwin" Date: Wed, 9 Mar 2022 16:07:29 -0500 Subject: [PATCH 1/2] Should launch in fullscreen mode --- tangy-form-reducer.js | 5 +++++ tangy-form.js | 5 +++++ test/tangy-form_test.html | 22 ++++++++++++++++++++++ 3 files changed, 32 insertions(+) diff --git a/tangy-form-reducer.js b/tangy-form-reducer.js index 7ee82bfe..b6cdb32d 100644 --- a/tangy-form-reducer.js +++ b/tangy-form-reducer.js @@ -72,6 +72,11 @@ const tangyFormReducer = function (state = initialState, action) { if (newState.form.hideClosedItems === true) newState.items.forEach(item => item.hidden = !item.open) if (newState.form.linearMode === true) newState.items.forEach(item => item.hideButtons = true) if (newState.form.fullscreen === true) newState.items.forEach(item => item.fullscreen = true) + if (newState.form.fullscreenOnly === true) { + newState.form.fullscreen = true + newState.items.forEach(item => item.fullscreenOnly = true) + newState.items.forEach(item => item.fullscreenEnabled = true) + } return newState case 'OPEN_ALL_ITEMS': diff --git a/tangy-form.js b/tangy-form.js index 83e2a9fb..e0975841 100644 --- a/tangy-form.js +++ b/tangy-form.js @@ -339,6 +339,11 @@ export class TangyForm extends PolymerElement { static get properties() { return { + fullscreenOnly: { + type: Boolean, + value: false, + reflectToAttribute: true + }, fullscreen: { type: Boolean, value: false, diff --git a/test/tangy-form_test.html b/test/tangy-form_test.html index efdec057..f193f2e0 100644 --- a/test/tangy-form_test.html +++ b/test/tangy-form_test.html @@ -329,6 +329,21 @@ + + +