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

fix(ui-library): ensure property naming number field (831) #940

Merged
merged 1 commit into from
Mar 27, 2024

Conversation

JpunktWpunkt
Copy link
Contributor

@JpunktWpunkt JpunktWpunkt commented Feb 21, 2024

related to #831 and #834

angsherpa456
angsherpa456 previously approved these changes Feb 21, 2024
angsherpa456
angsherpa456 previously approved these changes Feb 21, 2024
angsherpa456
angsherpa456 previously approved these changes Feb 21, 2024
angsherpa456
angsherpa456 previously approved these changes Feb 21, 2024
davidken91
davidken91 previously approved these changes Feb 21, 2024
Copy link
Contributor

@thrbnhrtmnn thrbnhrtmnn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hasUnit is not working as intended in Storybook. Instead of a boolean there should be three options, that can be selected via a radio: "none", "prefix", "suffix" with "none" being the default.

If hasUnit is either "prefix" or "suffix", the "unit" prop should be shown in the props panel. If hasUnit="none", the "unit" prop should not be shown.

Also in Storybook the FormCaptionGroup example story under "Dependencies" is missing a hint message in both instances and also a hint message icon in the second instance.

@JpunktWpunkt JpunktWpunkt dismissed stale reviews from davidken91 and angsherpa456 via 583516a March 6, 2024 12:38
@JpunktWpunkt JpunktWpunkt marked this pull request as draft March 8, 2024 09:53
@ChristianHoffmannS2 ChristianHoffmannS2 changed the title Fix/831 ensure property naming number field fix(ui-library): ensure property naming number field (831) Mar 8, 2024
@JpunktWpunkt JpunktWpunkt marked this pull request as ready for review March 21, 2024 13:19
Copy link
Contributor

@thrbnhrtmnn thrbnhrtmnn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @JpunktWpunkt , the changes already look really good. I would just change a few minor things, before I will approve:

  1. unitPosition should per default be "prefix" and we should not offer the "none" option
  2. hasUnit please update the Description in the props panel to "Choose if component has a unit.". We should be a bit more consistent with similar props like hasLabel
  3. Please align the order of the props in the props panel to the Excel (I think only unitPosition and the section "Accessibility" and "Technical Attributes" need to be adjusted)

thrbnhrtmnn
thrbnhrtmnn previously approved these changes Mar 22, 2024
Copy link
Contributor

@thrbnhrtmnn thrbnhrtmnn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Storybook looks perfect now!

By the way, did you also solve #834 with the implementation? If so, please let me know so I can close the other issue :-)

@JpunktWpunkt
Copy link
Contributor Author

JpunktWpunkt commented Mar 22, 2024

Storybook looks perfect now!

By the way, did you also solve #834 with the implementation? If so, please let me know so I can close the other issue :-)

Yes, I did :) #834 with the last commit when I checked the order I saw that name was missing :)

@JpunktWpunkt JpunktWpunkt linked an issue Mar 22, 2024 that may be closed by this pull request
2 tasks
@@ -335,7 +337,9 @@ export class BlrInputFieldNumber extends LitElement {
@select=${this.handleSelect}
placeholder=${this.placeholder || ''}
/>
${hasUnit ? html` <div class="${unitClasses}">${this.unit}</div> ` : nothing}
${this.unitPosition === 'prefix' || this.unitPosition === 'suffix'
? html` <div class="${unitClasses}">${this.unit}</div> `
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please remove the extra space on both side of html

@@ -257,40 +259,40 @@ export class BlrInputFieldNumber extends LitElement {
[`${this.sizeVariant}`]: this.sizeVariant,
[this.stepperVariant || 'split']: this.stepperVariant || 'split',
'error-input': this.hasError || false,
'prepend': hasUnit && !!this.prependUnit,
// 'prepend': this.unitPosition === 'prefix' || this.unitPosition === 'suffix',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can this be removed?

},

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please remove this additional line.

angsherpa456
angsherpa456 previously approved these changes Mar 22, 2024
Copy link
Contributor

@angsherpa456 angsherpa456 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@JpunktWpunkt JpunktWpunkt added the 🦹 needs:reviewers (code) The issue or pull request needs additional code reviewers label Mar 22, 2024
@faselbaum faselbaum removed the request for review from davidken91 March 22, 2024 14:23
thrbnhrtmnn
thrbnhrtmnn previously approved these changes Mar 22, 2024
@ChristianHoffmannS2 ChristianHoffmannS2 dismissed thrbnhrtmnn’s stale review March 26, 2024 12:39

The merge-base changed after approval.

@ChristianHoffmannS2 ChristianHoffmannS2 force-pushed the develop branch 2 times, most recently from 358f467 to 99c0c93 Compare March 26, 2024 13:22
@thrbnhrtmnn thrbnhrtmnn requested review from thrbnhrtmnn and removed request for thrbnhrtmnn March 27, 2024 09:05
@thrbnhrtmnn thrbnhrtmnn removed the 🦹 needs:reviewers (code) The issue or pull request needs additional code reviewers label Mar 27, 2024
@thrbnhrtmnn thrbnhrtmnn self-requested a review March 27, 2024 09:07
@JpunktWpunkt JpunktWpunkt changed the base branch from develop to develop_old March 27, 2024 10:16
@faselbaum faselbaum force-pushed the fix/831-ensure-property-naming-number-field branch from 1c4a456 to a4a5c19 Compare March 27, 2024 15:02
@faselbaum faselbaum changed the base branch from develop_old to develop March 27, 2024 15:02
@faselbaum faselbaum force-pushed the fix/831-ensure-property-naming-number-field branch from a4a5c19 to e5d178e Compare March 27, 2024 15:38
@thrbnhrtmnn thrbnhrtmnn removed the request for review from RubirajAccenture March 27, 2024 15:38
@faselbaum faselbaum self-requested a review March 27, 2024 15:41
@faselbaum faselbaum requested a review from angsherpa456 March 27, 2024 15:42
Copy link
Contributor

@angsherpa456 angsherpa456 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@JpunktWpunkt JpunktWpunkt merged commit d4ab9b7 into develop Mar 27, 2024
4 of 5 checks passed
@JpunktWpunkt JpunktWpunkt deleted the fix/831-ensure-property-naming-number-field branch March 27, 2024 16:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
6 participants