Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FSADT1-861: BC Service Card form to Apply for a Client Number #589

Merged
merged 15 commits into from
Oct 31, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
45 changes: 34 additions & 11 deletions frontend/src/assets/styles/global.scss
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,9 @@ hr {

.cds--inline-notification-content {
width: 100%;
font-size: 0.875rem;
font-style: normal;
font-weight: 400;
}

div#app {
Expand Down Expand Up @@ -635,6 +638,21 @@ div#app {
row-gap: 1.5rem;
}

.card {
align-self: stretch;
display: flex;
flex-direction: column;
padding: 2rem;
border-radius: 0.5rem;
border: 1px solid var(--light-theme-border-border-subtle-00, #dfdfe1);
background: #fff;
max-width: 50.4375rem;
}

.divider {
margin: 1.5rem 0 1.5rem 0;
}

.grouping-01 {
align-self: stretch;
display: flex;
Expand Down Expand Up @@ -707,16 +725,6 @@ div#app {
background: #fff;
}

.grouping-tbd {
align-self: stretch;
display: flex;
flex-direction: column;
padding: 1.5rem 0 1.5rem 0;
border-radius: 0.5rem;
border: 1px solid var(--light-theme-border-border-subtle-00, #dfdfe1);
background: #fff;
}

.grouping-06 {
display: flex;
flex-direction: column;
Expand Down Expand Up @@ -889,6 +897,21 @@ div#app {
align-self: stretch;
}

.cds-text-input-label {
color: var(--light-theme-text-text-primary, #131315);
font-family: BC Sans;
font-size: 0.75rem;
font-style: normal;
font-weight: 400;
line-height: 1rem;
letter-spacing: 0.02rem;
padding-bottom: 0.5rem;
}

.cds-text-input-required-label {
color: var(--light-theme-text-text-error, #B32001);
}

cds-modal::part(dialog) {
border-radius: 0.5rem;
}
Expand Down Expand Up @@ -1551,4 +1574,4 @@ cds-accordion-item.grouping-05-internal:not([open]) {
padding: 2.5rem 2.5rem 2.5rem 18.5rem;
max-width: calc(100vw - 21rem);
}
}
}
30 changes: 13 additions & 17 deletions frontend/src/components/MainHeaderComponent.vue
Original file line number Diff line number Diff line change
Expand Up @@ -175,23 +175,19 @@ const logoutModalActive = ref(false);
<cds-modal-body><p></p></cds-modal-body>

<cds-modal-footer>
<cds-modal-footer-button
kind="secondary"
data-modal-close
class="cds--modal-close-btn">
Cancel
</cds-modal-footer-button>

<cds-modal-footer-button
kind="danger"
class="cds--modal-submit-btn"
v-on:click="$session?.logOut"
>
Logout
<Logout16 slot="icon" />
</cds-modal-footer-button>

</cds-modal-footer>
<cds-modal-footer-button
kind="secondary"
data-modal-close class="cds--modal-close-btn">
Cancel
</cds-modal-footer-button>
<cds-modal-footer-button
kind="danger"
class="cds--modal-submit-btn"
v-on:click="$session?.logOut">
Logout
<Logout16 slot="icon" />
</cds-modal-footer-button>
</cds-modal-footer>
</cds-modal>

</template>
61 changes: 36 additions & 25 deletions frontend/src/components/forms/DropdownInputComponent.vue
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ const props = defineProps<{
initialValue: string;
validations: Array<Function>;
errorMessage?: string;
requiredLabel?: boolean;
}>();

//Events we emit during component lifecycle
Expand Down Expand Up @@ -144,30 +145,40 @@ revalidateBus.on(() => validateInput(selectedValue.value));

<template>
<div class="grouping-03">
<cds-combo-box
v-for="time in comboBoxMountTime"
:key="time"
:id="id"
filterable
:helper-text="tip"
:label="placeholder"
:title-text="label"
:value="selectedValue"
:invalid="error ? true : false"
:invalidText="error"
@cds-combo-box-selected="selectItem"
:data-focus="id"
:data-scroll="id"
v-shadow="3"
>
<cds-combo-box-item
v-for="option in inputList"
:key="option.code"
:value="option.name"
:data-id="option.code"
:data-value="option.name">
{{ option.name }}
</cds-combo-box-item>
</cds-combo-box>
<div class="input-group">
<div class="cds--text-input__label-wrapper">
<label :for="id" class="cds-text-input-label">
{{ label }}
<span v-if="requiredLabel"
class="cds-text-input-required-label">
(required)
</span>
</label>
</div>
<cds-combo-box
v-for="time in comboBoxMountTime"
:key="time"
:id="id"
filterable
:helper-text="tip"
:label="placeholder"
:value="selectedValue"
:invalid="error ? true : false"
:invalidText="error"
@cds-combo-box-selected="selectItem"
:data-focus="id"
:data-scroll="id"
v-shadow="3"
>
<cds-combo-box-item
v-for="option in inputList"
:key="option.code"
:value="option.name"
:data-id="option.code"
:data-value="option.name">
{{ option.name }}
</cds-combo-box-item>
</cds-combo-box>
</div>
</div>
</template>
55 changes: 33 additions & 22 deletions frontend/src/components/forms/MultiselectInputComponent.vue
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ const props = defineProps<{
initialValue: string;
validations: Array<Function>;
errorMessage?: string;
requiredLabel?: boolean;
}>();

//Events we emit during component lifecycle
Expand Down Expand Up @@ -114,28 +115,38 @@ revalidateBus.on(() => validateInput(selectedValue.value));
<template>
<div class="grouping-03">
<div class="frame-02">
<cds-multi-select
:id="id"
:value="selectedValue"
:label="selectedValue"
:title-text="label"
:helper-text="tip"
:invalid="error ? true : false"
:invalid-text="error"
filterable
@cds-multi-select-selected="selectItems"
:data-focus="id"
:data-scroll="id"
>
<cds-multi-select-item
v-for="option in inputList"
:key="option.code"
:value="option.name"
:data-id="option.code"
:data-value="option.name">
{{ option.name }}
</cds-multi-select-item>
</cds-multi-select>
<div class="input-group">
<div class="cds--text-input__label-wrapper">
<label :for="id" class="cds-text-input-label">
{{ label }}
<span v-if="requiredLabel"
class="cds-text-input-required-label">
(required)
</span>
</label>
</div>
<cds-multi-select
:id="id"
:value="selectedValue"
:label="selectedValue"
:helper-text="tip"
:invalid="error ? true : false"
:invalid-text="error"
filterable
@cds-multi-select-selected="selectItems"
:data-focus="id"
:data-scroll="id"
>
<cds-multi-select-item
v-for="option in inputList"
:key="option.code"
:value="option.name"
:data-id="option.code"
:data-value="option.name">
{{ option.name }}
</cds-multi-select-item>
</cds-multi-select>
</div>
</div>
</div>
</template>
51 changes: 32 additions & 19 deletions frontend/src/components/forms/TextInputComponent.vue
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ const props = defineProps<{
validations: Array<Function>;
errorMessage?: string;
mask?: string;
requiredLabel?: boolean;
}>();

//Events we emit during component lifecycle
Expand Down Expand Up @@ -103,7 +104,7 @@ watch(
);

// Tells whether the current change was done manually by the user.
const isUserEvent = ref(false)
const isUserEvent = ref(false);

const selectValue = (event: any) => {
selectedValue.value = event.target.value;
Expand All @@ -113,27 +114,39 @@ const selectValue = (event: any) => {

<template>
<div class="grouping-02" v-if="enabled">
<cds-text-input
v-if="enabled"
:id="id"
:placeholder="placeholder"
:value="selectedValue"
:label="enabled ? label : null"
:helper-text="tip"
:disabled="!enabled"
:invalid="error ? true : false"
:invalid-text="error"
v-masked="mask"
@blur="(event:any) => validateInput(event.target.value)"
@input="selectValue"
:data-focus="id"
:data-scroll="id"
:data-id="'input-' + id"
/>
<div class="input-group">
<div class="cds--text-input__label-wrapper">
<label :for="id" class="cds-text-input-label">
{{ enabled ? label : null }}
<span v-if="requiredLabel"
class="cds-text-input-required-label">
(required)
</span>
</label>
</div>
<cds-text-input
v-if="enabled"
:id="id"
:placeholder="placeholder"
:value="selectedValue"
:helper-text="tip"
:disabled="!enabled"
:invalid="error ? true : false"
:invalid-text="error"
v-masked="mask"
@blur="(event:any) => validateInput(event.target.value)"
@input="selectValue"
:data-focus="id"
:data-scroll="id"
:data-id="'input-' + id"
/>
</div>
</div>

<div v-if="!enabled" class="grouping-04">
<div :data-scroll="id" class="grouping-04-label"><span :for="id" class="label-01">{{ label }}</span></div>
<div :data-scroll="id" class="grouping-04-label">
<span :for="id" class="label-01">{{ label }}</span>
</div>
<span class="text-01">{{ modelValue }}</span>
</div>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,6 @@ watch([autoCompleteResult], () => {

watch([detailsData], () => {
if (detailsData.value) {
console.log(JSON.stringify(detailsData.value));
selectedValue.streetAddress = detailsData.value.streetAddress.trim();
selectedValue.city = detailsData.value.city;
selectedValue.province = detailsData.value.province;
Expand Down
Loading
Loading