Mischa POSLAWSKY [Fri, 6 Sep 2019 18:57:42 +0000 (20:57 +0200)]
cli: mkclioptions core program presets
Input group names for selected entries from debian coreutils, bsdmainutils,
git subcommands, others.
Mischa POSLAWSKY [Mon, 21 Feb 2022 11:41:10 +0000 (12:41 +0100)]
font: path to roboto fonts changed on debian
Mischa POSLAWSKY [Tue, 11 Jan 2022 00:12:17 +0000 (01:12 +0100)]
word/edit: hide manual crop coordinates input
Managed by js interface, values not needed as long as it works correctly.
Being hidden prevents workarounds so bugs are maybe forced to be fixed.
Mischa POSLAWSKY [Sun, 20 Feb 2022 17:57:11 +0000 (18:57 +0100)]
word/memory: webkit prefix for turned card faces
Workaround for some versions of Safari where images are always visible.
Mischa POSLAWSKY [Thu, 10 Feb 2022 03:17:00 +0000 (04:17 +0100)]
word/finder: .large images with multiple subcategories
Automatic subdivision for a result similar to the previous cover attribute
without requiring manual maintenance.
Mischa POSLAWSKY [Sat, 19 Feb 2022 15:37:07 +0000 (16:37 +0100)]
word: hover gallery captions only on larger screens
Mischa POSLAWSKY [Thu, 17 Feb 2022 14:35:53 +0000 (15:35 +0100)]
digraphs: fix relative path in shiar include tool
Another one missed in commit
v1.10-63-g00ffc9287b (2018-03-05)
[tools: fix includes from relative paths for perl v5.26].
Mischa POSLAWSKY [Thu, 17 Feb 2022 14:33:39 +0000 (15:33 +0100)]
tools: validate utf8 encoding in stdin/out
Recommended by perlcritic. Not likely to be an issue in these cases,
but might yet catch some data errors.
Mischa POSLAWSKY [Thu, 10 Feb 2022 03:21:22 +0000 (04:21 +0100)]
word/finder: order by grade within levels
Mischa POSLAWSKY [Mon, 7 Feb 2022 18:13:36 +0000 (19:13 +0100)]
word/finder: caption text width bound to figure box
Mischa POSLAWSKY [Tue, 8 Feb 2022 22:04:22 +0000 (23:04 +0100)]
word/finder: emulate gallery page in javascript
Prepare replacement of the server-side index page.
Mischa POSLAWSKY [Mon, 7 Feb 2022 17:42:16 +0000 (18:42 +0100)]
word: margin exception in common stylesheet
Mischa POSLAWSKY [Thu, 27 Jan 2022 22:45:50 +0000 (23:45 +0100)]
source: create missing cache subdirectories
Fix storage of modules such as Shiar_Sheet::Keyboard.
Mischa POSLAWSKY [Sun, 23 Jan 2022 00:51:12 +0000 (01:51 +0100)]
word/edit: read fractional crop coordinates
Clean up various separators (,-x;:/) from manual input into common comma,
and allow dot for possible future fractions in large numbers:
UPDATE word SET image = jsonb_set(image, '{crop32}',
regexp_replace(image->>'crop32', '[^0-9,]', ',', 'g')
) WHERE image->>'crop32' IS NOT NULL;
Decided against dividing by 1000 to simplify code, but this would do that:
UPDATE word SET image = jsonb_set(image, '{crop32}',
to_jsonb(array_to_string(array(
SELECT unnest(string_to_array(image->>'crop32', ','))::float / 1000
), ','))
) WHERE image->>'crop32' IS NOT NULL;
Mischa POSLAWSKY [Sat, 22 Jan 2022 20:34:45 +0000 (21:34 +0100)]
word/edit: fix (vertical) scale with different aspect ratios
Mischa POSLAWSKY [Wed, 19 Jan 2022 19:35:36 +0000 (20:35 +0100)]
word/edit: image container only needed for source
Mischa POSLAWSKY [Mon, 17 Jan 2022 17:15:59 +0000 (18:15 +0100)]
unicode: mathematical hebrew symbols like greek a-b
Mischa POSLAWSKY [Mon, 17 Jan 2022 17:15:50 +0000 (18:15 +0100)]
unicode: colour blocks row of hues in unicode 12.0
Mischa POSLAWSKY [Mon, 17 Jan 2022 17:13:24 +0000 (18:13 +0100)]
unicode: one set of barb arrows from unicode 7.0
Replace old private use variants by "modern" codepoints. Limit to one
representative from Arrows-C for now.
Mischa POSLAWSKY [Mon, 17 Jan 2022 17:11:18 +0000 (18:11 +0100)]
unicode: circled playstation control symbols
Variant set completed in Unicode 11.0 with limited font support.
Mischa POSLAWSKY [Mon, 17 Jan 2022 17:09:04 +0000 (18:09 +0100)]
unicode: precomposed alchemical symbols for elements
Semantic glyphs have been available since Unicode version 6.0 (2010)
so about time to replace these visual approximations.
Mischa POSLAWSKY [Sat, 8 Jan 2022 05:37:06 +0000 (06:37 +0100)]
charset: map classic ti-8x calculators
Closest unicode representations afaict, based on http://shiar.nl/calc/z80
images and guesses from manuals and emulators for unclear semantics.
Mischa POSLAWSKY [Sat, 8 Jan 2022 04:00:39 +0000 (05:00 +0100)]
charset: legacy map ansel (and extensions)
Reference: Wikipedia, <https://www.gedsite.com/en/character-encoding.htm>
Mischa POSLAWSKY [Wed, 29 Dec 2021 18:35:36 +0000 (19:35 +0100)]
charset: compare unknown glyphs in custom tables
Ignore missing classes in Perl v5.28 for Unicode v13.0 legacy computing
symbols, while keeping unassigned code points in unicode blocks (various
gaps in Greek overview).
Mischa POSLAWSKY [Wed, 29 Dec 2021 18:28:12 +0000 (19:28 +0100)]
charset: skip empty petscii rows
Fix startpoint offset.
Mischa POSLAWSKY [Wed, 29 Dec 2021 18:05:59 +0000 (19:05 +0100)]
charset: fix unicode name in cell title
Broken in commit
v1.11-65-g57d7837d68 (2019-07-03)
[charset: silence warning of empty cell arguments].
Mischa POSLAWSKY [Tue, 28 Dec 2021 15:24:38 +0000 (16:24 +0100)]
charset: legacy encodings petscii, atascii, msx, zx-spectrum
Sources now represented by unicode 13.0 legacy computing symbols.
Copied from Wikipedia.
Mischa POSLAWSKY [Wed, 12 Jan 2022 15:20:58 +0000 (16:20 +0100)]
word/edit: separate consecutive input fields
Spacing between multiple elements within each row.
Mischa POSLAWSKY [Tue, 11 Jan 2022 05:53:54 +0000 (06:53 +0100)]
word/quiz: report table to save user actions
Setup basic logging system to gather usage events serverside for debugging
and hopefully difficulty analysis later on. Initially always enabled while
in private testing.
Mischa POSLAWSKY [Tue, 11 Jan 2022 01:01:31 +0000 (02:01 +0100)]
word/edit: track touch events in crop area
Reimplement mobile support lost with croppie.
Mischa POSLAWSKY [Mon, 10 Jan 2022 16:13:17 +0000 (17:13 +0100)]
word/edit: custom crop interface superior to croppie
Some minimal js and absolute positioning can replace
v1.12-226-gca5f2bee8e
(2022-02-07) [word/edit: croppie js thumbnail selection interface]
to exact demands, without rounding errors and restricted zoom control.
Mischa POSLAWSKY [Thu, 6 Jan 2022 18:23:29 +0000 (19:23 +0100)]
word/edit: search button toggles empty input
Minimal javascript to make hiding work as expected.
Mischa POSLAWSKY [Thu, 6 Jan 2022 18:21:39 +0000 (19:21 +0100)]
word/edit: search input form in hierarchy navigation
Styling to move it to top, and hide input until focused.
Mischa POSLAWSKY [Wed, 5 Jan 2022 00:36:16 +0000 (01:36 +0100)]
word/edit: croppie js thumbnail selection interface
Replace the unintuitive coordinate helper by a free (mit) external library
(~9kB compressed) to select and preview an image crop window.
Reference: <https://github.com/Foliotek/Croppie>
Mischa POSLAWSKY [Wed, 5 Jan 2022 00:04:53 +0000 (01:04 +0100)]
word/edit: crop coordinates separate from convert parameters
Move -area value into a distinct image column crop32:
UPDATE word SET image = jsonb_insert(
image #- '{convert,0}' #- '{convert,0}',
'{crop32}', image->'convert'->1
)
WHERE image->'convert'->>0 = '-area';
UPDATE word SET image = jsonb_insert(
image #- '{convert,2}' #- '{convert,2}',
'{crop32}', image->'convert'->3
)
WHERE image->'convert'->>2 = '-area'
AND image->'convert'->>0 = '-gravity';
Remaining usage may be influenced by preceding options and need manual
inspection.
Mischa POSLAWSKY [Mon, 3 Jan 2022 04:16:33 +0000 (05:16 +0100)]
word/edit: sub signatures in ImagePrep methods
Mischa POSLAWSKY [Mon, 3 Jan 2022 04:05:43 +0000 (05:05 +0100)]
word: change directory name of 3:2 thumbnails
Specific to convert options (identified by resulting shape), not language.
Mischa POSLAWSKY [Mon, 3 Jan 2022 04:55:10 +0000 (05:55 +0100)]
word/edit: decrease webp image quality to 40%
Reduce average size from 24kB to 18kB with the same increased resolution,
more comparable to 11kB JPEGs.
Mischa POSLAWSKY [Mon, 3 Jan 2022 04:04:12 +0000 (05:04 +0100)]
word/edit: method generate() to create thumbnail variants
Mischa POSLAWSKY [Sun, 2 Jan 2022 00:00:51 +0000 (01:00 +0100)]
word/edit: remap/rename priority levels
Insert additional levels to distinguish within animal groups, such as
recent mapping of different species with various levels of notoriety.
Splits priority 2 and 3 into two options each:
UPDATE word SET prio = prio + 1 WHERE prio > 2;
0 essential → essential : core terms and categorisation
1 basic → ubiquitous : beginner level words
2 common → basic : internationally known
→ common : expected, readily recognisable
3 distinctive → distinctive : native names, popular genus
4 optional → specialised : significant species in field
5 invisible → rare : expert distinction or knowledge
invisible : placeholder group, ignored
For future listings of people, it would map to Brian Buckley's hierarchy
of fame <https://briandbuckley.com/2017/08/07/a-hierarchy-of-fame/>:
1 = l8 Incredulity (Einstein, Shakespeare, Jesus, Batman)
2 = l7 Reassessment− (Joan of Arc, Bill Gates, Moses, Vader)
3 = l6 Hiccup− (Newton, Jobs, Lennon, Lancelot, Jabba)
4 = l5 Ambivalence (Elon Musk, Carl Sagan, Lovecraft, Boba Fett)
5 = l4 Hiccup+ (Randall Munroe, Shigeru Miyamoto, Sylvia Plath, Mothma)
6 = l3 Reassessment+ (Douglas Hofstadter, Carl Linnaeus, Kosh)
7 = l2 Explanation (notable not famous: Lu Xun, Jane Espenson, Sim Aloo)
Mischa POSLAWSKY [Thu, 30 Dec 2021 07:14:29 +0000 (08:14 +0100)]
word/quiz: category selection from location hash
Mischa POSLAWSKY [Fri, 31 Dec 2021 13:35:54 +0000 (14:35 +0100)]
word/memory: manual grid size override option
Temporary workaround for unsupported aspect ratio and custom amounts.
Mischa POSLAWSKY [Fri, 31 Dec 2021 04:02:19 +0000 (05:02 +0100)]
word/edit: ignore missing binomial name in wp download
Mischa POSLAWSKY [Thu, 30 Dec 2021 07:05:35 +0000 (08:05 +0100)]
word/memory: pick cards to fit grid dimensions
Mischa POSLAWSKY [Thu, 30 Dec 2021 07:04:53 +0000 (08:04 +0100)]
word/multichoice: stop when answers run out
Mischa POSLAWSKY [Thu, 30 Dec 2021 02:41:30 +0000 (03:41 +0100)]
word/multichoice: skip imageless (unanswerable) questions
Mischa POSLAWSKY [Thu, 30 Dec 2021 07:04:05 +0000 (08:04 +0100)]
word/memory: celebration pause after each rotation
Normal visibility for 2 seconds.
Mischa POSLAWSKY [Thu, 30 Dec 2021 06:20:31 +0000 (07:20 +0100)]
word/memory: mirrored duplication of unpaired images
More typical gameplay operating on normal selections, but still distinguish
matches for added difficulty.
Mischa POSLAWSKY [Thu, 30 Dec 2021 04:55:21 +0000 (05:55 +0100)]
word/quiz: filter preset category and empty subcategories
Calculate category tree from references added in the previous commit.
Configure preset.cat to test.
Mischa POSLAWSKY [Thu, 30 Dec 2021 02:31:41 +0000 (03:31 +0100)]
word: language includes for general use
Reorder translation columns and add (possibly foreign) category references
as stable interface for quizzes. Exceptional category index format for .en
English moved to extensionless include.
Mischa POSLAWSKY [Thu, 30 Dec 2021 00:40:43 +0000 (01:40 +0100)]
word/quiz: preset configuration filters level
Manual option preset.cat to test difficulty selection.
Mischa POSLAWSKY [Thu, 30 Dec 2021 00:40:13 +0000 (01:40 +0100)]
word/wijzer: answers below image in vertical orientation
Mischa POSLAWSKY [Mon, 27 Dec 2021 02:02:38 +0000 (03:02 +0100)]
word/wijzer: quiz based on Per Seconde Wijzer
Mischa POSLAWSKY [Wed, 29 Dec 2021 05:04:34 +0000 (06:04 +0100)]
word/quiz: fisher-yates shuffle algorithm
Fixes very bad randomisation in some browsers.
Reference: <https://javascript.info/array-methods#shuffle-an-array>
Mischa POSLAWSKY [Wed, 29 Dec 2021 05:00:24 +0000 (06:00 +0100)]
word/quiz: common js function to shuffle arrays
Mischa POSLAWSKY [Thu, 30 Dec 2021 04:57:50 +0000 (05:57 +0100)]
word/quiz: common base class for all subpages
Only json loading from multichoice to start with.
Mischa POSLAWSKY [Thu, 30 Dec 2021 04:54:04 +0000 (05:54 +0100)]
word/quiz: rename initial subpage to multichoice
Free the generic name since most pages will be quizzes.
Mischa POSLAWSKY [Mon, 27 Dec 2021 00:00:54 +0000 (01:00 +0100)]
word: ignore non-numeric selection arguments
Mischa POSLAWSKY [Wed, 29 Dec 2021 04:23:31 +0000 (05:23 +0100)]
word: webp images at double resolution
Modern compression format supported by modern Imagemagick and browsers,
efficient enough to allow 600x400 quality (better detail @2x pixel density
or as workaround for upscaled covers and in quizzes, until dedicated
alternatives) at acceptable file sizes ~25kB.
Mischa POSLAWSKY [Sun, 26 Dec 2021 20:06:12 +0000 (21:06 +0100)]
word: store data entries as prepared subarrays
Time to split strings is comparable to directly loading structured values.
Considered hashes for scalability with more (optional) columns, but not
worth the cost at this time.
Benchmark loading 1264 rows in perl:
rate memory size
strings 468/s 52kB 15kB
split 257/s 152kB "
arrays 221/s 133kB 17kB
hashes 126/s 188kB 27kB
Mischa POSLAWSKY [Thu, 23 Dec 2021 02:12:13 +0000 (03:12 +0100)]
word/memory: fullscreen grid of 4x3 or 2x6 cards
Mischa POSLAWSKY [Thu, 23 Dec 2021 01:27:04 +0000 (02:27 +0100)]
word/memory: celebration animation on completion
Mischa POSLAWSKY [Sat, 11 Dec 2021 12:29:03 +0000 (13:29 +0100)]
dieren: fill remaining placeholders for paard and hond
Replace adjective forms by distinct entities, but also an obscure easter egg
over non-animal turnpaard.
Mischa POSLAWSKY [Wed, 24 Nov 2021 23:58:19 +0000 (00:58 +0100)]
source: subdirectory index for tools/
Mischa POSLAWSKY [Wed, 24 Nov 2021 23:51:05 +0000 (00:51 +0100)]
source: highlight preprocessor code like statements
Identify @media parts in css.
Mischa POSLAWSKY [Wed, 24 Nov 2021 23:48:49 +0000 (00:48 +0100)]
source: cache syntax highlighted html
Massive speedup on repeated requests since Text::VimColor is so slow
(but the only readily available option for plp syntax).
Mischa POSLAWSKY [Wed, 24 Nov 2021 23:45:16 +0000 (00:45 +0100)]
source: prepare highlighted lines before output
Code cleanup for readability and to facilitate upcoming caching.
Mischa POSLAWSKY [Wed, 17 Nov 2021 01:37:54 +0000 (02:37 +0100)]
browser: replace inter-feature links to caniuse.com
Mischa POSLAWSKY [Mon, 15 Nov 2021 20:28:21 +0000 (21:28 +0100)]
browser: indicate release year in version title
Mischa POSLAWSKY [Mon, 15 Nov 2021 20:27:24 +0000 (21:27 +0100)]
browser: retain prefix of merged agents
Mischa POSLAWSKY [Mon, 15 Nov 2021 19:41:49 +0000 (20:41 +0100)]
browser: merge deprecated agents on newer target
Originally inverted to keep deprecated names, but after this long Edge
should be more familiar than IE. Special case and_chr to keep shorter
"And." though.
Mischa POSLAWSKY [Mon, 15 Nov 2021 19:09:42 +0000 (20:09 +0100)]
browser: determine development status from version release
Instead of assuming special status of last three version columns,
convert version metadata into a lookup hash so it can be used.
Mischa POSLAWSKY [Mon, 15 Nov 2021 18:15:25 +0000 (19:15 +0100)]
browser: store only changed values in version support
Full storage does not scale well, taking over 1.2s to load the current 23MB
perl structure (mostly indentation, minified it's 3MB like the original json).
Simple deduplication reduces this to 2.6MB pp (800kB as json) which takes only
0.2s excluding parsing.
Mischa POSLAWSKY [Mon, 15 Nov 2021 18:12:57 +0000 (19:12 +0100)]
browser: coalesce duplicate agent version in caniuse data
Development version 95 in android is joined with and_chr.
Mischa POSLAWSKY [Mon, 15 Nov 2021 18:11:35 +0000 (19:11 +0100)]
browser: drop unused agent version metadata
Mischa POSLAWSKY [Mon, 15 Nov 2021 17:58:01 +0000 (18:58 +0100)]
browser: omit empty values from caniuse data
Currently shaves 460kB off 23MB.
Mischa POSLAWSKY [Mon, 15 Nov 2021 16:52:10 +0000 (17:52 +0100)]
latin: capital suetterlin letters on hover
Show additional divergent forms already available in font.
Restriction on first-letter seems broken in Firefox, but wanted to prevent
all-caps samples.
Mischa POSLAWSKY [Mon, 15 Nov 2021 16:51:46 +0000 (17:51 +0100)]
latin: enlarge horizontal domino tiles to letter height
Mischa POSLAWSKY [Mon, 15 Nov 2021 16:51:07 +0000 (17:51 +0100)]
latin: alternate tap styling using crossed dashes
Mischa POSLAWSKY [Mon, 15 Nov 2021 16:50:43 +0000 (17:50 +0100)]
latin: palm graffiti font placeholder
Downloaded from https://blogfonts.com/graffiti--palm--1.font as preview.
Mischa POSLAWSKY [Mon, 15 Nov 2021 16:43:40 +0000 (17:43 +0100)]
word: common language handling in quiz
Replace hardcoded nl include by same ?lang result as overview.
Mischa POSLAWSKY [Mon, 15 Nov 2021 16:42:59 +0000 (17:42 +0100)]
word/quiz: answer selection styling (hover)
Mischa POSLAWSKY [Mon, 1 Nov 2021 23:38:57 +0000 (00:38 +0100)]
word: prevent infinite loops on invalid data
Mischa POSLAWSKY [Wed, 10 Nov 2021 23:37:52 +0000 (00:37 +0100)]
sc: redirect subpage aliases to preferred canonical names
Mischa POSLAWSKY [Wed, 10 Nov 2021 03:15:57 +0000 (04:15 +0100)]
sc: display upgrade range of 0 bonus damage
Fix missing values for Hellbat and Tempest, after initial workaround in
commit
v1.11-29-g7813ee51b9 (2018-05-10) [visibility of optional hellbat
bonus damage].
Mischa POSLAWSKY [Wed, 10 Nov 2021 01:27:04 +0000 (02:27 +0100)]
sc: lotv unit updates to patch 5.0.2 BU
Changes copied from Blizzard patch notes.
Retains all earlier values since patch 4.1.4 hidden behind a hardcoded
version variable.
Mischa POSLAWSKY [Thu, 28 Oct 2021 00:20:18 +0000 (02:20 +0200)]
sc: lower precedence of hp order
Mischa POSLAWSKY [Sat, 16 Oct 2021 15:50:38 +0000 (17:50 +0200)]
sc: apply html paging to 404 errors
Mischa POSLAWSKY [Tue, 9 Nov 2021 03:10:17 +0000 (04:10 +0100)]
sitemap: link recently developed pages
In order: dieren, codec, sc/hots, keyboard, sample, plan.
Mischa POSLAWSKY [Mon, 8 Nov 2021 19:19:33 +0000 (20:19 +0100)]
base: group related columns and rows
Divide about halfway conveniently after decimal, and after every 8-16 rows.
Mischa POSLAWSKY [Sun, 7 Nov 2021 04:40:47 +0000 (05:40 +0100)]
index: link scope in git messages to existing page
Assumes prefix matches page names.
Mischa POSLAWSKY [Sun, 7 Nov 2021 04:36:31 +0000 (05:36 +0100)]
index: retrieve git log from cached text include
While git is fast, it still results in a ~50ms command for an otherwise
static ~5ms landing page. Run `make -B UPDATE` as post-commit git hook
(and post-rewrite, and post-checkout) on live checkouts.
Mischa POSLAWSKY [Sun, 7 Nov 2021 00:41:07 +0000 (01:41 +0100)]
digraphs: parse recent plan9 character additions
Fix syntax warnings for 2020-05-19 change in upstream repository to support
higher-plane unicode references. Record download rule for future validation.
Mischa POSLAWSKY [Tue, 2 Nov 2021 02:52:55 +0000 (03:52 +0100)]
codec: page intro from format data
Mischa POSLAWSKY [Tue, 2 Nov 2021 00:02:43 +0000 (01:02 +0100)]
codec: derive column groups from generation sequence
Not specific to hardcoded image formats.
Mischa POSLAWSKY [Sat, 30 Oct 2021 02:42:10 +0000 (04:42 +0200)]
codec: audio type with 5 lossy music formats
Some readily available facts and opinions about the most popular audio
codecs AFAIK.
Mischa POSLAWSKY [Sun, 31 Oct 2021 01:00:48 +0000 (02:00 +0100)]
codec: page request overrides image type
Mischa POSLAWSKY [Fri, 29 Oct 2021 20:28:14 +0000 (22:28 +0200)]
codec: constant table column widths
Styling hack assuming ≤10 similar cells regardless of missing data.
Mischa POSLAWSKY [Sun, 31 Oct 2021 00:59:03 +0000 (02:59 +0200)]
codec: netpbm (pnm) format for completeness
Does not compress, but significant for legacy Unix compatibility
and good as lossless baseline.
Mischa POSLAWSKY [Fri, 29 Oct 2021 18:52:23 +0000 (20:52 +0200)]
codec: calculate theoretical minimal overhead
Optimal sizes of 1x1 black images as researched by Jon Sneyers [1]
with later AVIF data [2] and 2021-10-25 breakthrough for JPEG-XL [3].
An example found for HEIC [4] may not be golfed, but kind of irrelevant
considering the container. Its 212 byte JPEG-2000 example is larger than a
naive ImageMagick conversion.
[1] https://cloudinary.com/blog/one_pixel_is_worth_three_thousand_words
[2] https://twitter.com/jonsneyers/status/
1333037638840967169
[3] https://twitter.com/jonsneyers/status/
1452727349405966341
[4] https://github.com/mathiasbynens/small/commit/
e05a006dd