+ 'author': 'autor',
+ 'epoch': 'epoka',
+ 'genre': 'gatunek',
+ 'kind': 'rodzaj'
+ },
+ show_filter: ['authors', 'themes'],
+ show_dividers: ['authors', 'themes'],
+ db_version: '1.0'
+ });
+ Readings.catalogue = new Readings.Catalogue().open();
+ return Readings.initialized = true;
+ };
+
+ $(document).on('pageinit', '#page-categories', function(ev) {
+ Readings.init();
+ return $('#list-categories').Readings('CategoryList');
+ });
+
+ rcategory = /category=(\w+)/;
+
+ rtag = /tag=([a-z0-9-]+)/;
+
+ rtagid = /tag_id=([0-9]+)/;
+
+ $(document).on('pageinit', "#page-tags", function(ev, ui) {
+ var category;
+ category = rcategory.exec($(this).attr('data-url'));
+ if (category != null) {
+ category = category[1];
+ if (category != null) {
+ return $(this).Readings('list', {
+ sql: "SELECT * FROM tag WHERE category=? ORDER BY sort_key",
+ params: [category],
+ filter: Readings.config.get('show_filter').indexOf(category) >= 0,
+ mapper: function(rec) {
+ return new Readings.Tag(rec, category);
+ },
+ dividers: Readings.config.get('show_dividers').indexOf(category) >= 0
+ });