-
Notifications
You must be signed in to change notification settings - Fork 5
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
Clear button element instead of iron-icon with class #117
Conversation
ui-helpers/cosmoz-clear-button.html
Outdated
width: 16px !important; | ||
min-height: 16px; | ||
height: 16px; | ||
position: absolute; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
position:absolute
specifiies position from the edges of the closest relative
ancestor.
In the filter dialog context, this ancestor is the paper-dialog-scrollable
element, so the clear icon will always be on the top right of the dialog.
I guess it should be fixed with something like:
:host {
display: block;
position: relative
cosmoz-omnitable-column-amount.html
Outdated
@@ -33,8 +35,7 @@ <h3 style="margin: 0;">[[ title ]]</h3> | |||
</paper-input> | |||
</div> | |||
</paper-dropdown-menu> | |||
<iron-icon icon="clear" class="header-clear-filter" | |||
on-tap="resetFilter" visible$="[[ hasFilter(filter.*) ]]"></iron-icon> | |||
<cosmoz-clear-button on-tap="resetFilter" hidden$="[[ !hasFilter(filter.*) ]]"></cosmoz-clear-button> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can use click
instead of tap
event. See https://www.polymer-project.org/2.0/docs/devguide/gesture-events
cosmoz-omnitable-column-date.html
Outdated
@@ -34,8 +35,7 @@ <h3 style="margin: 0;">[[ title ]]</h3> | |||
</paper-input> | |||
</div> | |||
</paper-dropdown-menu> | |||
<iron-icon icon="clear" class="header-clear-filter" | |||
on-tap="resetFilter" visible$="[[ hasFilter(filter.*) ]]"></iron-icon> | |||
<cosmoz-clear-button on-tap="resetFilter" hidden$="[[ !hasFilter(filter.*) ]]"></cosmoz-clear-button> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Prefer click
event
@@ -33,8 +34,7 @@ <h3 style="margin: 0;">[[ title ]]</h3> | |||
</datetime-local> | |||
</div> | |||
</paper-dropdown-menu> | |||
<iron-icon icon="clear" class="header-clear-filter" | |||
on-tap="resetFilter" visible$="[[ hasFilter(filter.*) ]]"></iron-icon> | |||
<cosmoz-clear-button on-tap="resetFilter" hidden$="[[ !hasFilter(filter.*) ]]"></cosmoz-clear-button> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Prefer click
event
cosmoz-omnitable-column-number.html
Outdated
@@ -28,8 +32,7 @@ <h3 style="margin: 0;">[[ title ]]</h3> | |||
</paper-input> | |||
</div> | |||
</paper-dropdown-menu> | |||
<iron-icon icon="clear" class="header-clear-filter" | |||
on-tap="resetFilter" visible$="[[ hasFilter(filter.*) ]]"></iron-icon> | |||
<cosmoz-clear-button on-tap="resetFilter" hidden$="[[ !hasFilter(filter.*) ]]"></cosmoz-clear-button> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Prefer click
event
cosmoz-omnitable-column-time.html
Outdated
@@ -30,8 +31,7 @@ <h3 style="margin: 0;">[[ title ]]</h3> | |||
</paper-input> | |||
</div> | |||
</paper-dropdown-menu> | |||
<iron-icon icon="clear" class="header-clear-filter" | |||
on-tap="resetFilter" visible$="[[ hasFilter(filter.*) ]]"></iron-icon> | |||
<cosmoz-clear-button on-tap="resetFilter" hidden$="[[ !hasFilter(filter.*) ]]"></cosmoz-clear-button> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Prefer click
event
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could also please rebase, to ease merging of PR
Currently needed to display the clear button in the filters-dialog (PR #90) without having to include the styles into the template.