-
Notifications
You must be signed in to change notification settings - Fork 0
datepicker.rb
TADA Tadashi edited this page Nov 10, 2017
·
2 revisions
編集画面に日付選択カレンダーを表示させます。
tdiary-contribからdatepickerプラグインを取得し、配置してください
編集画面の日付の横にカレンダーのアイコンが表示されます。
http://farm9.staticflickr.com/8442/7783433476_0eba3772f9_o.png
アイコンをクリックすると、カレンダーが表示されて、日付選択が可能になります。
http://farm8.staticflickr.com/7246/7783443576_068d3d3901_o.png
-
セキュア環境でも動作します
-
カレンダーの配色を変更したい場合
- tdiary-contribからjquery_ui_themeプラグインを取得し、配置してください
- [設定]-[jQuery UI Theme]からテーマを指定してください
- テーマは http://jqueryui.com/themeroller/ から好みのものを選び、アルファベット小文字で指定してください
- デフォルトは base です
- http://jqueryui.com/download/?themeParams=%3Fctl%3Dthemeroller#stable-themes から引用
1.8.22 Themes: base, black-tie, blitzer, cupertino, dark-hive, dot-luv, eggplant, excite-bike, flick, hot-sneaks, humanity, le-frog, mint-choc, overcast, pepper-grinder, redmond, smoothness, south-street, start, sunny, swanky-purse, trontastic, ui-darkness, ui-lightness, vader.
- cssにて .jquery-ui-calendar を指定し、jQuery UI にて用意されているアイコンが表示されています 。
- themeを変更することでアイコンの色も追随しています。