|
124 | 124 | </Link.Button>
|
125 | 125 | </div>
|
126 | 126 | </div>
|
127 |
| - <div slot="middle" class:icons={state === 'icons'}> |
| 127 | + <div slot="middle" class="middle-container" class:icons={state === 'icons'}> |
128 | 128 | {#if progressCard}
|
129 | 129 | <Tooltip placement="right" disabled={state !== 'icons'}>
|
130 | 130 | <a
|
|
240 | 240 | <span slot="tooltip">{projectOption.name}</span>
|
241 | 241 | </Tooltip>
|
242 | 242 | {/each}
|
243 |
| - <div class="only-mobile divider"> |
244 |
| - <Divider /> |
245 |
| - </div> |
246 |
| - <div class="only-mobile"> |
247 |
| - <Tooltip placement="right" disabled={state !== 'icons'}> |
248 |
| - <a |
249 |
| - href={`/console/project-${project.region}-${project.$id}/settings`} |
250 |
| - on:click={() => { |
251 |
| - trackEvent('click_menu_settings'); |
252 |
| - }} |
253 |
| - class="link" |
254 |
| - ><span class="link-icon"><Icon icon={IconCog} size="s" /></span |
255 |
| - ><span |
256 |
| - class:no-text={state === 'icons'} |
257 |
| - class:has-text={state === 'open'} |
258 |
| - class="link-text">Settings</span |
259 |
| - ></a> |
260 |
| - <span slot="tooltip">Settings</span> |
261 |
| - </Tooltip> |
262 |
| - </div> |
| 243 | + {#if project} |
| 244 | + <div class="mobile-tablet-settings"> |
| 245 | + <Tooltip placement="right" disabled={state !== 'icons'}> |
| 246 | + <a |
| 247 | + href={`/console/project-${project.region}-${project.$id}/settings`} |
| 248 | + on:click={() => { |
| 249 | + trackEvent('click_menu_settings'); |
| 250 | + sideBarIsOpen = false; |
| 251 | + }} |
| 252 | + class="link" |
| 253 | + class:active={isSelected('/settings') && !isSelected('sites')} |
| 254 | + ><span class="link-icon"><Icon icon={IconCog} size="s" /></span |
| 255 | + ><span |
| 256 | + class:no-text={state === 'icons'} |
| 257 | + class:has-text={state === 'open'} |
| 258 | + class="link-text">Settings</span |
| 259 | + ></a> |
| 260 | + <span slot="tooltip">Settings</span> |
| 261 | + </Tooltip> |
| 262 | + </div> |
| 263 | + {/if} |
263 | 264 | </Layout.Stack>
|
264 | 265 | {:else if $isSmallViewport}
|
265 | 266 | <div class="action-buttons">
|
|
359 | 360 | {/if}
|
360 | 361 |
|
361 | 362 | <style lang="scss">
|
| 363 | + .middle-container { |
| 364 | + flex: 1; |
| 365 | + overflow-y: visible; |
| 366 | + max-height: none; |
| 367 | + } |
| 368 | +
|
| 369 | + .mobile-tablet-settings { |
| 370 | + display: block; |
| 371 | + margin-top: var(--space-6, 12px); |
| 372 | +
|
| 373 | + &::before { |
| 374 | + content: ''; |
| 375 | + display: block; |
| 376 | + height: 1px; |
| 377 | + background: var(--border-neutral, #ededf0); |
| 378 | + margin-bottom: var(--space-6, 12px); |
| 379 | + } |
| 380 | +
|
| 381 | + @media (min-width: 1024px) { |
| 382 | + display: none; |
| 383 | + } |
| 384 | + } |
| 385 | +
|
362 | 386 | .link {
|
363 | 387 | display: flex;
|
364 | 388 | height: 32px;
|
|
578 | 602 | width: 100%;
|
579 | 603 | }
|
580 | 604 |
|
581 |
| - .bottom { |
582 |
| - @media (min-width: 1024px) { |
583 |
| - height: var(--base-32, 32px); |
584 |
| - } |
585 |
| - } |
586 |
| -
|
587 | 605 | :global(button.collapse) {
|
588 | 606 | transform: translateX(-10px);
|
589 | 607 | }
|
|
0 commit comments