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

Custom accordion with border color as the color attribute #3452

Closed
albertcito opened this issue Mar 4, 2025 · 1 comment
Closed

Custom accordion with border color as the color attribute #3452

albertcito opened this issue Mar 4, 2025 · 1 comment
Labels
question Further information is requested

Comments

@albertcito
Copy link
Contributor

Description

The idea is to add a border in the accordion, but it should be dynamic. It should have the same color that the current accordion color. For instance the next code, but it will not convert the classes border-{color}-500 in border-red-500 or any other color.

<UAccordion
  color="red"
  :ui="{
    container: 'mb-0.5 border border-{color}-500 rounded-lg overflow-y-hidden',
    item: {
      base: 'border-t border-{color}-500',
      padding: 'py-1.5 px-2.5',
    },
    default: {
      class: 'ring-0 rounded-none',
      size: 'xl',
    },
  }"
  :items="[{
    label: 'Getting Started',
    content: 'Getting started content',
  }, {
    label: 'Installation',
    content: 'Installation content',
  }, {
    label: 'Configuration',
    content: 'Configuration content',
  }, {
    label: 'Usage',
    content: 'Usage content',
  }]"
/>
@albertcito albertcito added the question Further information is requested label Mar 4, 2025
@albertcito
Copy link
Contributor Author

Thi sis ui:2 I'll work in ui3 in order to try to do it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant