Skip to content

Commit

Permalink
feat(design)!: rename native select sass and paths (#2475)
Browse files Browse the repository at this point in the history
Co-authored-by: Elain T. <[email protected]>
  • Loading branch information
griest024 and xelaint committed Jun 15, 2023
1 parent 1a5c02c commit 990919f
Show file tree
Hide file tree
Showing 16 changed files with 19 additions and 19 deletions.
4 changes: 2 additions & 2 deletions libs/design/scss/theme.scss
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
@use '../src/atoms/form/error-message/error-message-theme' as error-message;
@use '../src/atoms/form/form-field/form-field/form-field-theme' as form-field;
@use '../src/atoms/form/input/input-theme' as input;
@use '../src/atoms/form/select/select/select-theme' as select;
@use '../src/atoms/form/native-select/native-select-theme' as native-select;
@use '../src/atoms/loading-icon/loading-icon-theme' as loading-icon;
@use '../src/atoms/progress-indicator/progress-indicator-theme' as progress-indicator;
@use '../src/molecules/accordion/accordion-item/accordion-item-theme' as accordion-item;
Expand Down Expand Up @@ -61,7 +61,7 @@
@include error-message.daff-error-message-theme($theme);
@include form-field.daff-form-field-theme($theme);
@include input.daff-input-theme($theme);
@include select.daff-select-theme($theme);
@include native-select.daff-native-select-theme($theme);
@include loading-icon.daff-loading-icon-theme($theme);
@include progress-indicator.daff-progress-indicator-theme($theme);

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Select Component
# Native Select Component

`daff-native-select` is a form control element that can be used in forms to select a value from a set of options.

Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
@use 'sass:map';
@use '../../../../../scss/core';
@use '../../../../../scss/theming';
@use '../../../../scss/core';
@use '../../../../scss/theming';

@mixin daff-select-theme($theme) {
@mixin daff-native-select-theme($theme) {
$gray: core.daff-map-deep-get($theme, 'core.gray');
$base-contrast: core.daff-map-deep-get($theme, 'core.base-contrast');
$black: core.daff-map-deep-get($theme, 'core.black');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import {
} from '@angular/forms';
import { By } from '@angular/platform-browser';

import { DaffNativeSelectComponent } from './select.component';
import { DaffNativeSelectComponent } from './native-select.component';

@Component({
template: `
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@ import {
} from '@angular/core';
import { NgControl } from '@angular/forms';

import { DaffFormFieldControl } from '../../form-field/form-field-control';
import { DaffFormFieldControl } from '../form-field/form-field-control';

@Component({
// eslint-disable-next-line @angular-eslint/component-selector
selector: 'select[daff-native-select]',
template: '<ng-content></ng-content>',
styleUrls: ['./select.component.scss'],
styleUrls: ['./native-select.component.scss'],
encapsulation: ViewEncapsulation.None,
changeDetection: ChangeDetectionStrategy.OnPush,
providers: [
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { CommonModule } from '@angular/common';
import { NgModule } from '@angular/core';

import { DaffNativeSelectComponent } from './select/select.component';
import { DaffNativeSelectComponent } from './native-select.component';

@NgModule({
imports: [
Expand Down
2 changes: 2 additions & 0 deletions libs/design/src/atoms/form/native-select/public_api.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
export * from './native-select.component';
export { DaffNativeSelectModule } from './native-select.module';
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import {
import { By } from '@angular/platform-browser';

import { DaffInputModule } from '../input/public_api';
import { DaffNativeSelectModule } from '../select/public_api';
import { DaffNativeSelectModule } from '../native-select/public_api';
import { DaffQuantityFieldComponent } from './quantity-field.component';
import { DaffQuantityInputComponent } from './quantity-input/quantity-input.component';
import { DaffQuantitySelectComponent } from './quantity-select/quantity-select.component';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { NgModule } from '@angular/core';
import { ReactiveFormsModule } from '@angular/forms';

import { DaffInputModule } from '../input/public_api';
import { DaffNativeSelectModule } from '../select/public_api';
import { DaffNativeSelectModule } from '../native-select/public_api';
import { DaffQuantityFieldComponent } from './quantity-field.component';
import { DaffQuantityInputComponent } from './quantity-input/quantity-input.component';
import { DaffQuantitySelectComponent } from './quantity-select/quantity-select.component';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import { Subject } from 'rxjs';
import {
DaffNativeSelectModule,
DaffNativeSelectComponent,
} from '../../select/public_api';
} from '../../native-select/public_api';
import { DaffQuantitySelectComponent } from './quantity-select.component';

@Component({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {
} from '@angular/core';
import { NgControl } from '@angular/forms';

import { DaffNativeSelectComponent } from '../../select/public_api';
import { DaffNativeSelectComponent } from '../../native-select/public_api';

/**
* Create an array of numbers from min to max, not including max.
Expand Down
2 changes: 0 additions & 2 deletions libs/design/src/atoms/form/select/public_api.ts

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { By } from '@angular/platform-browser';

import { DaffFormFieldModule } from '../../atoms/form/form-field/public_api';
import { DaffInputModule } from '../../atoms/form/input/input.module';
import { DaffNativeSelectModule } from '../../atoms/form/select/select.module';
import { DaffNativeSelectModule } from '../../atoms/form/native-select/public_api';
import { DaffQtyDropdownComponent } from './qty-dropdown.component';

@Component({ template: '<daff-qty-dropdown [qty]="qtyValue" [id]="idValue"></daff-qty-dropdown>' })
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { FormsModule } from '@angular/forms';

import { DaffFormFieldModule } from '../../atoms/form/form-field/form-field.module';
import { DaffInputModule } from '../../atoms/form/input/input.module';
import { DaffNativeSelectModule } from '../../atoms/form/select/select.module';
import { DaffNativeSelectModule } from '../../atoms/form/native-select/public_api';
import { DaffQtyDropdownComponent } from './qty-dropdown.component';

@NgModule({
Expand Down
2 changes: 1 addition & 1 deletion libs/design/src/public_api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export * from './atoms/form/form-field/public_api';
export * from './atoms/form/error-message/public_api';
export * from './atoms/image/public_api';
export * from './atoms/form/input/public_api';
export * from './atoms/form/select/public_api';
export * from './atoms/form/native-select/public_api';
export * from './atoms/form/checkbox/public_api';
export * from './atoms/form/quantity-field/public_api';
export * from './atoms/container/public_api';
Expand Down

0 comments on commit 990919f

Please sign in to comment.