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

[Status] Add attr option + deprecated non camelCase option #177

Merged
merged 9 commits into from
Dec 12, 2023

Conversation

cavasinf
Copy link
Collaborator

@cavasinf cavasinf commented Nov 9, 2023

Description

  • Deprecate non camelCase with_dot option
  • Add safe bool check on options values
  • Add status_dot component
  • add attr option to each component

Usage

<div>
    {{ status('Not animated', {withDot : true, animated : false, color: 'blue'}) }}
    {{ status('Lite with dot', {withDot : true, color: 'red', lite: true}) }}
    {{ status('No dot', {color: 'green'}) }}
    {{ status('id', {attr: {id : 'status_id'}}) }}

    {{ status_dot() }}
    {{ status_dot({color : 'purple'}) }}
    {{ status_dot({color : 'red', animated : false}) }}
    {{ status_dot({attr: {id : 'status_dot_id'}}) }}

    {{ status_indicator() }}
    {{ status_indicator({color : 'orange'}) }}
    {{ status_indicator({color : 'red', animated : false}) }}
    {{ status_indicator({attr: {id : 'status_indicator_id'}}) }}
</div>

Visual

status

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • I updated the documentation (see here)
  • I agree that this code will be published under the MIT license

@cavasinf cavasinf added Status: Needs Review Not under investigation Feature Feature requested labels Nov 9, 2023
@cavasinf cavasinf added Status: Reviewed Has staff reply/investigation and removed Status: Needs Review Not under investigation labels Dec 8, 2023
@cavasinf
Copy link
Collaborator Author

cavasinf commented Dec 8, 2023

Ready to go 👍

@kevinpapst
Copy link
Owner

Do we have demos for these elements? I know you don't need them, but its really nice for visual review purposes.

kevinpapst
kevinpapst previously approved these changes Dec 11, 2023
@cavasinf
Copy link
Collaborator Author

cavasinf commented Dec 11, 2023

Looking through TablerBundle-Demo, I've found that I am blind..
There's already a status_dot component..

And even more, there's already demos for those components: https://github.com/kevinpapst/TablerBundle-Demo/blob/main/templates/components/status/status.html.twig

kevinpapst/TablerBundle-Demo#24

(happy ending 🤯)

@kevinpapst
Copy link
Owner

Hahaha, and you committed it last time? I told you: we are doing this job for too long 😁

@cavasinf
Copy link
Collaborator Author

and you committed it last time

Yes, I (re)did it in the status.html.twig component.

I told you: we are doing this job for too long

Christmas is almost here 😫

@cavasinf cavasinf changed the title [Status] Add status_dot component + attr option [Status] Add attr option + deprecated non camelCase option Dec 11, 2023
Co-authored-by: Kevin Papst <kevinpapst@users.noreply.github.com>
@kevinpapst kevinpapst merged commit 923ebb1 into kevinpapst:main Dec 12, 2023
2 checks passed
@kevinpapst
Copy link
Owner

Merci beaucoup 👍

@cavasinf cavasinf deleted the cavasinf-status branch December 12, 2023 15:49
@cavasinf
Copy link
Collaborator Author

Mit Vergnügen 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature Feature requested Status: Reviewed Has staff reply/investigation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants