Show story change times and compact list details

This commit is contained in:
tim
2026-10-01 15:42:48 +02:00
parent 13d7360f60
commit b536a1f116
5 changed files with 129 additions and 8 deletions
+16
View File
@@ -87,6 +87,22 @@ test('the Add stories textarea uses the smaller text size without shrinking othe
assert.equal(declarations('textarea')['font-size'], undefined);
});
test('story timestamps fit their text and chapter details use plain small text', () => {
const desktop = css.slice(css.indexOf('@media (min-width: 601px)'));
const date = declarations('.date');
assert.equal(date['white-space'], 'nowrap');
assert.equal(date['min-inline-size'], undefined);
const storyDate = declarations('.stories-table .date', desktop);
assert.equal(storyDate['inline-size'], '1%');
assert.equal(storyDate['min-inline-size'], undefined);
const details = declarations(".stories-table td[data-label='Chapters'] small");
assert.equal(details.display, 'block');
assert.equal(details['white-space'], 'nowrap');
assert.equal(details.background, undefined);
assert.equal(details.border, undefined);
assert.equal(details.padding, undefined);
});
function luminance(hex) {
const channels = hex.slice(1).match(/../g).map((channel) => {
const value = parseInt(channel, 16) / 255;