Skip to content

Commit

Permalink
update wording and apply same rules on key naming
Browse files Browse the repository at this point in the history
  • Loading branch information
ludovic35 committed Feb 5, 2025
1 parent 0c3e7f0 commit 703d865
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ struct ButtonConfiguration: View {
}

if model.layout == .iconAndText || model.layout == .textOnly {
DesignToolboxTextField(text: $model.text, prompt: "app_component_common_userText_prompt")
DesignToolboxTextField(text: $model.text, prompt: "app_components_common_userText_prompt")
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ struct EmptyState: View {
.frame(width: 160, height: 160, alignment: .center)

VStack(alignment: .center, spacing: theme.spaces.spaceFixedShorter) {
Text("app_component_emptyContent_text")
Text("app_components_emptyContent_text")
.typeHeadingMedium(theme)
Text("app_component_emptyContent_description_text")
Text("app_components_emptyContent_description_text")
.typeBodyDefaultSmall(theme)
}
.padding(.vertical, theme.spaces.spaceFixedMedium)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ struct LinkConfiguration: View {
}
}

DesignToolboxTextField(text: $model.text, prompt: "app_component_common_userText_prompt")
DesignToolboxTextField(text: $model.text, prompt: "app_components_common_userText_prompt")
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -162,10 +162,10 @@ struct SwitchConfiguration: View {
}
}

DisclosureGroup("Edit texts") {
DesignToolboxTextField(text: $model.labelContent, prompt: "app_component_common_userText_prompt", title: "app_components_switch_label_text")
DisclosureGroup("app_components_common_editContent_label") {
DesignToolboxTextField(text: $model.labelContent, prompt: "app_components_common_userText_prompt", title: "app_components_switch_label_text")
if model.helperText {
DesignToolboxTextField(text: $model.helperTextContent, prompt: "app_component_common_userText_prompt", title: "app_components_common_helperText_label")
DesignToolboxTextField(text: $model.helperTextContent, prompt: "app_components_common_userText_prompt", title: "app_components_common_helperText_label")
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ struct DesignToolboxTextField: View {
let prompt: String
let title: String

init(text: Binding<String>, prompt: String, title: String = "app_component_common_userText_label") {
init(text: Binding<String>, prompt: String, title: String = "app_components_common_userText_label") {
self.title = title
self.text = text
self.prompt = prompt
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,10 +103,8 @@
// MARK: - Component Screen

"app_components_common_viewCodeExample_label" = "View component code example";
"app_component_emptyContent_text" = "No content";
"app_component_emptyContent_description_text" = "This content is under construction and will be available very soon";
"app_component_common_userText_prompt" = "Enter a text";
"app_component_common_userText_label" = "Text";
"app_components_common_userText_prompt" = "Enter a text";
"app_components_common_userText_label" = "Text";
"app_components_common_layout_label" = "Layout";
"app_components_common_textOnlyLayout_label" = "Text only";
"app_components_common_iconAndTextLayout_label" = "Icon + text";
Expand All @@ -117,6 +115,12 @@
"app_components_common_divider_label" = "Divider";
"app_components_common_onError_label" = "On error";
"app_components_common_orientation_label" = "Orientation";
"app_components_common_editContent_label" = "Edit content";

// MARK: Components: Empty state

"app_components_emptyContent_text" = "No content";
"app_components_emptyContent_description_text" = "This content is under construction and will be available very soon";

// MARK: Components: Button

Expand Down

0 comments on commit 703d865

Please sign in to comment.