Skip to content

Commit

Permalink
web/satellite: update app css to append asterisk (*) to labels of req…
Browse files Browse the repository at this point in the history
…uired inputs

Added styling to auto-append asterisk (*) to labels of required inputs.
Added missing required attribute to text fields with 'required' validation rule.
Fixed small back navigation bug for create access grant flow.
Fixed file name typo for Applications page.

This change resolves post-merge comments of those changes #12452 and #12495.

Change-Id: I163e6999441501a92b2ea7a05bdc1d869d0cabeb
  • Loading branch information
VitaliiShpital authored and Storj Robot committed Feb 26, 2024
1 parent c06e9be commit 3bc8735
Show file tree
Hide file tree
Showing 12 changed files with 22 additions and 5 deletions.
File renamed without changes
4 changes: 4 additions & 0 deletions web/satellite/src/components/dialogs/CreateAccessDialog.vue
Expand Up @@ -341,6 +341,10 @@ const stepInfos: Record<CreateAccessStep, StepInfo> = {

[CreateAccessStep.ConfirmDetails]: new StepInfo(
() => {
if (accessTypes.value.includes(AccessType.APIKey)) {
return CreateAccessStep.ChoosePermission;
}

switch (passphraseOption.value) {
case PassphraseOption.EnterNewPassphrase: return CreateAccessStep.EnterNewPassphrase;
case PassphraseOption.GenerateNewPassphrase: return CreateAccessStep.PassphraseGenerated;
Expand Down
Expand Up @@ -55,6 +55,7 @@
persistent-counter
:hide-details="false"
autofocus
required
/>
<v-btn
v-if="!isDescriptionShown"
Expand Down
Expand Up @@ -52,6 +52,7 @@
:hide-details="false"
:rules="[ RequiredRule ]"
autofocus
required
>
<template #append-inner>
<password-input-eye-icons
Expand Down
Expand Up @@ -55,6 +55,7 @@
:hide-details="false"
:rules="[ RequiredRule ]"
autofocus
required
>
<template #append-inner>
<password-input-eye-icons
Expand Down
Expand Up @@ -28,7 +28,7 @@
id="First Name"
v-model="firstName"
:rules="[RequiredRule]"
label="First Name*"
label="First Name"
hide-details="auto"
required
/>
Expand All @@ -48,7 +48,7 @@
id="Company Name"
v-model="companyName"
:rules="[RequiredRule]"
label="Company Name*"
label="Company Name"
hide-details="auto"
required
/>
Expand All @@ -59,7 +59,7 @@
v-model="position"
:rules="[RequiredRule]"
:items="['Executive/C-Level', 'Director', 'Manager', 'Software Developer', 'Partner', 'Student/Professor', 'Other']"
label="Job Role*"
label="Job Role"
variant="outlined"
hide-details="auto"
required
Expand Down
Expand Up @@ -18,6 +18,7 @@
:hide-details="false"
:rules="[ RequiredRule ]"
autofocus
required
class="mt-2 mb-n4"
>
<template #append-inner>
Expand Down
Expand Up @@ -26,6 +26,7 @@
:rules="passphraseRules"
:hide-details="false"
autofocus
required
>
<template #append-inner>
<password-input-eye-icons
Expand Down
Expand Up @@ -15,6 +15,7 @@
:rules="nameRules"
maxlength="100"
class="mb-n2"
required
/>
</v-col>
<v-col cols="12">
Expand All @@ -26,7 +27,7 @@
:key="accessType"
v-model="typeInfos[accessType].model.value"
density="compact"
:hide-details="true"
hide-details
>
<template #label>
<span>{{ typeInfos[accessType].name }}</span>
Expand Down
5 changes: 5 additions & 0 deletions web/satellite/src/styles/styles.scss
Expand Up @@ -493,6 +493,11 @@ table {
background: rgb(var(--v-theme-background));
}

.v-field .v-field-label:has(~ .v-field__input:required)::after,
.v-field .v-field-label:has(~ .v-field__input > input:required)::after {
content: "*";
}

// fix for the table footer info width being too big for its small content
// a huge min-width was added in Vuetify 3.4.11
// https://github.com/vuetifyjs/vuetify/commit/a5254a2bada424c0bbdbc9d86fcea2afb6a86dc2
Expand Down
2 changes: 1 addition & 1 deletion web/satellite/src/types/applications.ts
Expand Up @@ -17,7 +17,7 @@ import HammerspaceIcon from '@/assets/apps/hammerspace.png';
import ElementsIcon from '@/assets/apps/elements.png';
import DockerIcon from '@/assets/apps/docker.png';
import PixelfedIcon from '@/assets/apps/pixelfed.png';
import MastodonIcon from '@/assets/apps/mastadon.png';
import MastodonIcon from '@/assets/apps/mastodon.png';
import DataverseIcon from '@/assets/apps/dataverse.png';
import CyberDuckIcon from '@/assets/apps/cyberduck.png';
import AtempoIcon from '@/assets/apps/atempo.png';
Expand Down
2 changes: 2 additions & 0 deletions web/satellite/src/views/Signup.vue
Expand Up @@ -80,6 +80,7 @@
hide-details="auto"
:type="showPassword ? 'text' : 'password'"
:rules="passwordRules"
required
@update:focused="showPasswordStrength = !showPasswordStrength"
>
<template #append-inner>
Expand All @@ -106,6 +107,7 @@
hide-details="auto"
:type="showPassword ? 'text' : 'password'"
:rules="repeatPasswordRules"
required
>
<template #append-inner>
<password-input-eye-icons
Expand Down

0 comments on commit 3bc8735

Please sign in to comment.