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

Bug in css for button #42

Closed
epykachu opened this issue Feb 17, 2020 · 3 comments
Closed

Bug in css for button #42

epykachu opened this issue Feb 17, 2020 · 3 comments
Assignees
Labels
bug Something isn't working
Projects

Comments

@epykachu
Copy link
Collaborator

It looks like the button references the base name of the css class instead whereas the class is declared as the css class name suffixed with the htmlId.

For instance:

test_button

Whereas the styles are declared as such:

.cssbuttonbasic_button_2051657361000 {font-weight: bold ;padding: 1px 10px ;margin: 2px 0 2px 0 ;text-decoration: none ;border-radius: 5px ;white-space: nowrap ;display: inline-block ;-webkit-appearance: none ;-moz-appearance: none ;border: 1px solid #1b5e20 ;color: #000000 ;background-color: #FFFFFF ;}
.cssbuttonbasic_button_2051657361000:hover {text-decoration: none ;cursor: pointer ;background-color: #1b5e20 ;color: #e8f5e9 ;}
.cssbuttonbasic_button_2051657361000:focus {outline: 0 ;}
.cssbuttonbasic_button_2051657361000:disabled {cursor: none ;background-color: #1b5e20 ;color: #43a047 ;font-style: italic ;}

@epykachu epykachu added the bug Something isn't working label Feb 17, 2020
@epykachu epykachu self-assigned this Feb 17, 2020
@epykure
Copy link
Owner

epykure commented Feb 17, 2020

This should be fixed with the new release. There was an issue in the function get_ref() in the module CssStyle.py. Normally I put a temporary workaround to solve this problem.

@epykachu
Copy link
Collaborator Author

I found also that there was an extra htmlId argument passed in the css_class method

@Property
def css_class(self):
"""
The internal class used to put a custom Style to this object.
Only 1 CSS class can be added to an HTML object
:rtype: Classes.CatalogButton.CatalogButton
"""
if self._css_class is None:
self._css_class = Classes.CatalogButton.CatalogButton(self.htmlObj._report, self.classList['main'], html_id=self.htmlObj.htmlId).basic()
return self._css_class

removing it seems to fix the issue. but not sure whether it's supposed to stay

@epykachu
Copy link
Collaborator Author

I'll close it - it works well

@epykachu epykachu added this to Done in Epyk UI Mar 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Epyk UI
  
Done
Development

No branches or pull requests

2 participants