Skip to content

dmak78/kirby-pikatime

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pikatime - Kirby Time Picking Field

This panel field for Kirby is a better time picker than the default supplied with Kirby.

License: MIT

Screenshot

Installation

Copy & Pasting

If not already existing, add a new fields folder to your site directory. Then copy or link this repositories whole content in a new pikatime folder there. Afterwards, your directory structure should look like this:

site/
    fields/
        pikatime/
            assests/
            pikatime.php

Git Submodule

If you would prefer to use a Git Submodule (which is more elegant in my opinion) you may follow along like this.

$ cd your/project/root
$ git submodule add https://github.com/jayshua/kirby-pikatime.git site/fields/pikatime

Usage

In blueprints

fields:
    time:
        label: Event Time
        type:  pikatime
        mode:  12

The mode property chooses whether the picker should display in 12 hour or 24 hour mode.

In templates

The pikatime field only saves time in basic 24-hour format. You can use the PHP date/time functions to format them as desired. See strtotime and Date/Time Functions on the PHP website.

Development

This is really just a note for me

To build (in assets/js): webpack pikatime.js --output-filename build.js -w

About

A better time picker field for Kirby

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 96.7%
  • CSS 2.0%
  • Other 1.3%