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

feat(desc): add :dir option #332

Merged
merged 4 commits into from
Aug 24, 2023
Merged

feat(desc): add :dir option #332

merged 4 commits into from
Aug 24, 2023

Conversation

kiaking
Copy link
Member

@kiaking kiaking commented Aug 24, 2023

Adds :dir option to SDesc. This will align label and value horizontally.

To control the divider, I've moved divider to SDescItem. And added additional prop to disable it.

Finally, when setting :dir to false, specify :labelWidth to define the width of label area grid.

<SDesc cols="2" gap="24" dir="row" label-width="96" :divider="false">
  ...
</SDesc>

Screenshot 2023-08-24 at 16 15 17

@kiaking kiaking added the enhancement New feature or request label Aug 24, 2023
@kiaking kiaking requested review from cuebit and brc-dd August 24, 2023 07:17
@kiaking kiaking self-assigned this Aug 24, 2023
@netlify
Copy link

netlify bot commented Aug 24, 2023

Deploy Preview for sefirot-story ready!

Name Link
🔨 Latest commit eb41c31
🔍 Latest deploy log https://app.netlify.com/sites/sefirot-story/deploys/64e71ae3daa6980008d3996f
😎 Deploy Preview https://deploy-preview-332--sefirot-story.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@netlify
Copy link

netlify bot commented Aug 24, 2023

Deploy Preview for sefirot-docs ready!

Name Link
🔨 Latest commit eb41c31
🔍 Latest deploy log https://app.netlify.com/sites/sefirot-docs/deploys/64e71ae320221c0008e33382
😎 Deploy Preview https://deploy-preview-332--sefirot-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@codecov
Copy link

codecov bot commented Aug 24, 2023

Codecov Report

Patch coverage: 95.00% and project coverage change: -0.02% ⚠️

Comparison is base (9257cca) 84.52% compared to head (eb41c31) 84.51%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #332      +/-   ##
==========================================
- Coverage   84.52%   84.51%   -0.02%     
==========================================
  Files         139      139              
  Lines       11163    11165       +2     
  Branches      630      630              
==========================================
  Hits         9436     9436              
- Misses       1727     1729       +2     
Files Changed Coverage Δ
lib/components/SDescDay.vue 100.00% <ø> (ø)
lib/components/SDescEmpty.vue 100.00% <ø> (ø)
lib/components/SDescLink.vue 100.00% <ø> (ø)
lib/components/SDescNumber.vue 100.00% <ø> (ø)
lib/components/SDescPill.vue 100.00% <ø> (ø)
lib/components/SDescState.vue 100.00% <ø> (ø)
lib/components/SDescText.vue 100.00% <ø> (ø)
lib/components/SDescItem.vue 94.44% <91.30%> (-5.56%) ⬇️
lib/components/SDesc.vue 100.00% <100.00%> (ø)

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@brc-dd
Copy link
Member

brc-dd commented Aug 24, 2023

Is this expected for cols = 1 (dir = column)?

Screen.Recording.2023-08-24.at.12.56.09.PM.mov

IG it should be like this (similar to cols = 1, dir = row, labelWidth < 0):

image

@kiaking
Copy link
Member Author

kiaking commented Aug 24, 2023

Is this expected for cols = 1 (dir = column)?

Ah shit, I'm gonna remove that option from story. That behaviour is expected. That's happening because "About" section has span 2. If all section has span 1, it works fine 👍

Copy link
Member

@cuebit cuebit left a comment

Choose a reason for hiding this comment

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

Couple of suggestions, otherwise LGTM 👍

docs/components/desc.md Outdated Show resolved Hide resolved
docs/components/desc.md Outdated Show resolved Hide resolved
kiaking and others added 2 commits August 24, 2023 17:54
Co-authored-by: Cue <hello@cuebit.dev>
Co-authored-by: Cue <hello@cuebit.dev>
@kiaking
Copy link
Member Author

kiaking commented Aug 24, 2023

Thanks a lot guys!

@kiaking kiaking merged commit daa8905 into main Aug 24, 2023
11 of 13 checks passed
@kiaking kiaking deleted the desc-row-direction branch August 24, 2023 08:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants