Skip to the content

Koyomi Calendars暦

Calendar pages as SVG: a day as an icon in 18 original designs, a whole month as a poster or a desk pad, and the page turning from one day to the next.

Koyomi is the Japanese word 暦 for the calendar. About the name

Contents

Reference

Calendar icons

import { … } from "@johnmorrisdotca/koyomi-calendars";

Exports

NameKindWhat it is
CALENDAR_HOUSINGSconstantThe housings an icon can sit in: square (the icon alone) and circle (on a coloured disc).
CALENDAR_PRESETSconstantThe named looks: flat, disc, ringed, tilted and disc-ringed.
CALENDAR_THEME_ALIASESconstantThe ten names of 0.12 and 0.13, still accepted: each reads as the theme that replaced it.
CALENDAR_THEME_LABELSconstantEach design's name for a picker, in English and in Japanese.
CALENDAR_THEMESconstantThe 18 designs, by name.
CALENDAR_TURN_MAXconstantThe most the icon may be turned either way, in degrees.
CALENDAR_YEAR_CLEARconstantThe share of the drawing's width the year keeps clear of the bottom of its zone.
CALENDAR_YEAR_MINconstantThe year is never smaller than this share of the drawing's width (its font size).
CalendarDatetypeA day on the calendar: a four-digit year, a month 1 to 12 and a day of the month.
CalendarHousingtypeOne of the housings in CALENDAR_HOUSINGS.
calendarIconfunctionAn original calendar-page SVG for a month, day and optional year.
CalendarIconOptionstypeWhat calendarIcon takes: the date, the design and the look of one calendar page.
calendarLayoutfunctionThe box, the page and the year's room of a theme, with and without a year.
CalendarLayouttypeWhere a theme puts the day and the year; a theme's layout says it once and the drawing and the tests both read it.
CalendarLooktypeThe three options a preset sets: a housing, rings and a turn.
calendarMoonfunctionThe phase of the moon at noon UTC on a date, in eighths of a lunation: 0 new, 2 first quarter, 4 full, 6 last quarter.
CalendarPresettypeOne of the names in CALENDAR_PRESETS.
calendarPresetOffunctionReads a preset's name.
CalendarThemetypeOne of the names in CALENDAR_THEMES.
calendarThemeOffunctionReads a design's name, or an older name for one.
calendarWeekendfunctionThe Saturday and the Sunday of the weekend a date is in.
JAPANESE_HOLIDAY_YEARSconstantThe first and last year the holiday rules describe.
japaneseHolidayfunctionThe public holiday of a day, in both languages.
JapaneseHolidaytypeA Japanese public holiday's name, in Japanese and in English.
japaneseHolidaysOffunctionEvery public holiday of a year, computed from the law's rules.
OLD_CALENDAR_YEARSconstantThe first and last year the old-calendar astronomy is held to.
oldCalendarDatefunctionThe old-calendar date of a Gregorian date, from the new moons and the sun's longitude.
OldDatetypeA date of the old Japanese calendar (旧暦, kyūreki): a month 1 to 12, a day, and whether the month is a leap month.
RokuyotypeOne day of the six-day cycle (六曜, rokuyō): its name, its reading and an English gloss.
ROKUYOconstantThe six days in order of (old month + old day) mod 6, with the reading and an English gloss.
rokuyoOffunctionThe day of the six-day cycle (六曜, rokuyō) of a Gregorian date.

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/koyomi-calendars 0.3.0.