|
| 1 | +<goab-block direction="column" gap="l"> |
| 2 | + <goab-block direction="column" gap="s"> |
| 3 | + <goab-text tag="h1" mb="0" mt="0"> |
| 4 | + <a href="https://github.com/GovAlta/ui-components/issues/3118" target="_blank" |
| 5 | + >3118</a |
| 6 | + > |
| 7 | + - MenuButton's width is not setting the correct width on wider elements |
| 8 | + </goab-text> |
| 9 | + <goab-text tag="p" mt="0"> |
| 10 | + Use these scenarios to confirm the React wrapper exposes the leading icon property |
| 11 | + and that the menu width matches the longest action label. |
| 12 | + </goab-text> |
| 13 | + </goab-block> |
| 14 | + |
| 15 | + <goab-divider mt="xl" mb="xl"></goab-divider> |
| 16 | + |
| 17 | + <!-- Critical Test Cases for the Fix --> |
| 18 | + <goab-text tag="h2"> |
| 19 | + Long Elements aren't forced to wrap |
| 20 | + </goab-text> |
| 21 | + |
| 22 | + <goab-menu-button text="Baseline actions" (onAction)="onAction($event)"> |
| 23 | + <goab-menu-action |
| 24 | + key="1" |
| 25 | + text="Action 1" |
| 26 | + action="action-1" |
| 27 | + icon="search" |
| 28 | + ></goab-menu-action> |
| 29 | + <goab-menu-action |
| 30 | + key="2" |
| 31 | + text="Very very very very very very very very very very very very long action" |
| 32 | + action="action-2" |
| 33 | + icon="search" |
| 34 | + ></goab-menu-action> |
| 35 | + <goab-menu-action |
| 36 | + key="3" |
| 37 | + text="Action 3" |
| 38 | + action="action-2" |
| 39 | + icon="search" |
| 40 | + ></goab-menu-action> |
| 41 | + </goab-menu-button> |
| 42 | + |
| 43 | + <!-- Critical Test Cases for the Fix --> |
| 44 | + <goab-text tag="h2"> |
| 45 | + Max width can be set forcing long elements to wrap |
| 46 | + </goab-text> |
| 47 | + |
| 48 | + <goab-menu-button |
| 49 | + maxWidth="500px" |
| 50 | + text="Baseline actions" |
| 51 | + (onAction)="onAction($event)" |
| 52 | + > |
| 53 | + <goab-menu-action |
| 54 | + key="1" |
| 55 | + text="Action 1" |
| 56 | + action="action-1" |
| 57 | + icon="search" |
| 58 | + ></goab-menu-action> |
| 59 | + <goab-menu-action |
| 60 | + key="2" |
| 61 | + text="Very very very very very very very very very very very very long action" |
| 62 | + action="action-2" |
| 63 | + icon="search" |
| 64 | + ></goab-menu-action> |
| 65 | + <goab-menu-action |
| 66 | + key="3" |
| 67 | + text="Action 3" |
| 68 | + action="action-2" |
| 69 | + icon="search" |
| 70 | + ></goab-menu-action> |
| 71 | + </goab-menu-button> |
| 72 | + |
| 73 | + |
| 74 | + <goab-divider mt="xl" mb="xl"></goab-divider> |
| 75 | + |
| 76 | + |
| 77 | + <!-- Critical Test Cases for the Fix --> |
| 78 | + <goab-text tag="h2"> |
| 79 | + Components on the right side of the screen will right align the menu options |
| 80 | + </goab-text> |
| 81 | + <goab-text tag="p"> |
| 82 | + You may may have to resize the browser to test this |
| 83 | + </goab-text> |
| 84 | + |
| 85 | + <goab-block direction="row" gap="l" width="100%"> |
| 86 | + <div style="width: 100%"></div> |
| 87 | + <goab-menu-button text="Baseline actions" (onAction)="onAction($event)"> |
| 88 | + <goab-menu-action |
| 89 | + key="1" |
| 90 | + text="Action 1" |
| 91 | + action="action-1" |
| 92 | + icon="search" |
| 93 | + ></goab-menu-action> |
| 94 | + <goab-menu-action |
| 95 | + key="2" |
| 96 | + text="Very very very very very very very very very very very very long action" |
| 97 | + action="action-2" |
| 98 | + icon="search" |
| 99 | + ></goab-menu-action> |
| 100 | + <goab-menu-action |
| 101 | + key="3" |
| 102 | + text="Action 3" |
| 103 | + action="action-2" |
| 104 | + icon="search" |
| 105 | + ></goab-menu-action> |
| 106 | + </goab-menu-button> |
| 107 | + </goab-block> |
| 108 | + |
| 109 | + |
| 110 | + <goab-divider mt="xl" mb="xl"></goab-divider> |
| 111 | + |
| 112 | + |
| 113 | + <goab-text tag="h2"> Regression tests </goab-text> |
| 114 | + |
| 115 | + <goab-grid minChildWidth="320px" gap="l"> |
| 116 | + <goab-block direction="column" gap="l" maxWidth="320px"> |
| 117 | + <goab-text tag="p">Some text</goab-text> |
| 118 | + <goab-menu-button text="Baseline actions" (onAction)="onAction($event)"> |
| 119 | + <goab-menu-action |
| 120 | + key="1" |
| 121 | + text="Action 1" |
| 122 | + action="action-1" |
| 123 | + icon="search" |
| 124 | + ></goab-menu-action> |
| 125 | + <goab-menu-action |
| 126 | + key="2" |
| 127 | + text="Very very very very very very very very very very very very long action" |
| 128 | + action="action-2" |
| 129 | + icon="search" |
| 130 | + ></goab-menu-action> |
| 131 | + <goab-menu-action |
| 132 | + key="3" |
| 133 | + text="Action 3" |
| 134 | + action="action-2" |
| 135 | + icon="search" |
| 136 | + ></goab-menu-action> |
| 137 | + </goab-menu-button> |
| 138 | + </goab-block> |
| 139 | + |
| 140 | + <goab-block direction="column" gap="l" maxWidth="320px"> |
| 141 | + <goab-text tag="p"> |
| 142 | + Lorem, ipsum dolor sit amet consectetur adipisicing elit. Dicta earum ipsa ullam |
| 143 | + beatae at atque non voluptas fugiat sapiente praesentium quisquam possimus |
| 144 | + repellat, illo voluptates nisi obcaecati quos. Mollitia, recusandae. |
| 145 | + </goab-text> |
| 146 | + <goab-menu-button text="Baseline actions" (onAction)="onAction($event)"> |
| 147 | + <goab-menu-action |
| 148 | + key="1" |
| 149 | + text="Action 1" |
| 150 | + action="action-1" |
| 151 | + icon="search" |
| 152 | + ></goab-menu-action> |
| 153 | + <goab-menu-action |
| 154 | + key="2" |
| 155 | + text="Very very very very very very very very very very very very long action" |
| 156 | + action="action-2" |
| 157 | + icon="search" |
| 158 | + ></goab-menu-action> |
| 159 | + <goab-menu-action |
| 160 | + key="3" |
| 161 | + text="Action 3" |
| 162 | + action="action-2" |
| 163 | + icon="search" |
| 164 | + ></goab-menu-action> |
| 165 | + </goab-menu-button> |
| 166 | + </goab-block> |
| 167 | + |
| 168 | + <goab-block direction="column" gap="l" maxWidth="320px"> |
| 169 | + <goab-text tag="p"> |
| 170 | + Lorem, ipsum dolor sit amet consectetur adipisicing elit. Dicta earum ipsa ullam |
| 171 | + beatae at atque non voluptas fugiat sapiente praesentium quisquam possimus |
| 172 | + repellat, illo voluptates nisi obcaecati quos. Mollitia, recusandae. |
| 173 | + </goab-text> |
| 174 | + <goab-menu-button text="Baseline actions" (onAction)="onAction($event)"> |
| 175 | + <goab-menu-action |
| 176 | + key="1" |
| 177 | + text="Action 1" |
| 178 | + action="action-1" |
| 179 | + icon="search" |
| 180 | + ></goab-menu-action> |
| 181 | + <goab-menu-action |
| 182 | + key="2" |
| 183 | + text="Very very very very very very very very very very very very long action" |
| 184 | + action="action-2" |
| 185 | + icon="search" |
| 186 | + ></goab-menu-action> |
| 187 | + <goab-menu-action |
| 188 | + key="3" |
| 189 | + text="Action 3" |
| 190 | + action="action-2" |
| 191 | + icon="search" |
| 192 | + ></goab-menu-action> |
| 193 | + </goab-menu-button> |
| 194 | + </goab-block> |
| 195 | + </goab-grid> |
| 196 | +</goab-block> |
0 commit comments