Skip to content

Commit

Permalink
refactor: change snake-case to camelCase for text types
Browse files Browse the repository at this point in the history
  • Loading branch information
pkorchak committed May 16, 2023
1 parent 2b7c6ec commit 5c686a2
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 12 deletions.
4 changes: 2 additions & 2 deletions src/app/model/form-element-type.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
export enum FormElementType {
SHORT_TEXT = 'short-text',
LONG_TEXT = 'long-text',
SHORT_TEXT = 'shortText',
LONG_TEXT = 'longText',
CHECKBOX = 'checkbox',
DATE = 'date',
EMAIL = 'email',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@
},
{
"label": "First Name",
"type": "short-text",
"type": "shortText",
"required": true,
"placeholder": "Enter first name"
},
{
"label": "Last Name",
"type": "short-text",
"type": "shortText",
"placeholder": "Enter last name"
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,29 +4,29 @@
"elements": [
{
"label": "First Name",
"type": "short-text",
"type": "shortText",
"required": true,
"placeholder": "Enter first name"
},
{
"label": "Last Name",
"type": "short-text",
"type": "shortText",
"required": true,
"placeholder": "Enter last name"
},
{
"label": "City",
"type": "short-text",
"type": "shortText",
"required": true
},
{
"label": "Street Address",
"type": "short-text",
"type": "shortText",
"required": true
},
{
"label": "Apt., Suite, Unit, Etc. (optional)",
"type": "short-text"
"type": "shortText"
},
{
"label": "ZIP Code",
Expand All @@ -47,7 +47,7 @@
},
{
"label": "Additional Information (optional)",
"type": "long-text"
"type": "longText"
}
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
</div>
</ng-template>

<ng-template ngSwitchCase="long-text">
<ng-template ngSwitchCase="longText">
<div class="main-controls">
<ng-template [ngTemplateOutlet]="mainControlsTmp"></ng-template>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<app-checkbox-form-element [element]="element"></app-checkbox-form-element>
</ng-template>

<ng-template ngSwitchCase="long-text">
<ng-template ngSwitchCase="longText">
<ng-template [ngTemplateOutlet]="label"></ng-template>
<app-textarea-form-element [element]="element"></app-textarea-form-element>
</ng-template>
Expand Down
File renamed without changes
File renamed without changes

0 comments on commit 5c686a2

Please sign in to comment.