Skip to content

Commit

Permalink
fix(cosmoz-omnitable-column-date): add css font-variant-numeric rule …
Browse files Browse the repository at this point in the history
…for date
  • Loading branch information
amandaavalencia committed Oct 23, 2024
1 parent 5a4e437 commit 32c4fac
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
13 changes: 6 additions & 7 deletions cosmoz-omnitable-column-date.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
/* eslint-disable no-return-assign */
import '@neovici/cosmoz-input';
import { html } from 'lit-html';
import { PolymerElement } from '@polymer/polymer/polymer-element';
import '@polymer/paper-dropdown-menu/paper-dropdown-menu';
import '@neovici/cosmoz-input';

import './ui-helpers/cosmoz-clear-button';

import { PolymerElement } from '@polymer/polymer/polymer-element';
import { html } from 'lit-html';

import { columnMixin } from './cosmoz-omnitable-column-mixin';
import './lib/cosmoz-omnitable-date-range-input';
import { defaultComputeSource } from './lib/utils-data';
Expand Down Expand Up @@ -95,13 +93,14 @@ class OmnitableColumnDate extends columnMixin(PolymerElement) {
}

renderCell(column, { item }) {
return getString(column, item);
return html`<div class="omnitable-cell-date">
${getString(column, item)}
</div>`;
}

renderEditCell(column, { item }, onItemChange) {
const onChange = (event) =>
onItemChange(fromInputString(event.target.value));

return html`<cosmoz-input
no-label-float
type="date"
Expand Down
3 changes: 2 additions & 1 deletion cosmoz-omnitable-styles.js
Original file line number Diff line number Diff line change
Expand Up @@ -344,6 +344,7 @@ export default css`
.tableContent .itemRow-cell paper-dropdown-menu {
margin-top: -20px;
}
cosmoz-omnitable-item-expand[expanded] {
Expand Down Expand Up @@ -437,7 +438,7 @@ export default css`
overflow: initial;
}
.omnitable-cell-number {
.omnitable-cell-number, .omnitable-cell-date {
font-variant-numeric: tabular-nums;
}
Expand Down

0 comments on commit 32c4fac

Please sign in to comment.