vitoria-training / sprout

0 stars 0 forks source link

feature:Added pulldown and modal functions. #35

Closed KeisukeKatagiri closed 8 months ago

KeisukeKatagiri commented 8 months ago

Validating pull-down lists and modal screens #34

【changes】 Color.elm ・Added background color when displaying modal.(translucentGray)

Top.elm ・Added [Contents] button status (contentsButtonStatus) in addition to list status (dropdownStatus). ・When the [Contents] button is pressed, the contentsButtonStatus is switched. ・The case statement in the subscription uses dropdownStatus and contentsButtonStatus to switch the pulldown display.

【Detail】 Color.elm ・I omitted it because I only added the color.

Top.elm ・[Contents] Add button status (contentsButtonStatus), When the [Contents] button is pressed, the state of the [Contents] button is switched, and four types of cases are created within the subscription.

When the contents button is pressed:Change contentsButtonStatus (ButtonOn/ButtonOff) subscription:① dropdownStatus is (Open) and contentsButtonStatus is (ButtonOn)         → Change dropdownStatus to (Close) and contentsButtonStatus to (ButtonOff)      ②dropdownStatus is (Open) and contentsButtonStatus is (ButtonOff)         → dropdownStatus (Close)      ③dropdownStatus is (Close) and contentsButtonStatus is (ButtonOn)         → dropdownStatus (Open)      ④ dropdownStatus is (Close" and contentsButtonStatus is (ButtonOff)         → Do nothing.

The assumed patterns for ① to ④ are as follows. ①:Pattern to close the list by pressing the [Contents] button while the list is displayed ②:Pattern to close the list by pressing anywhere on the screen other than the [Contents] button when the list is displayed ③:Pattern for displaying the list by pressing the [Contents] button when the list is not displayed ④:Pattern when pressing anywhere on the screen other than the [Contents] button when the list is not displayed