Commit Graph

251 Commits

Author SHA1 Message Date
dd27c3a873 changed tile background color 2021-07-08 12:33:28 +02:00
736841818d fixed font and other minor issues in title cards 2021-07-08 12:33:28 +02:00
c1868e22f4 minor codefactor fix 2021-07-08 12:33:28 +02:00
aabfc1d82e fixed card design 2021-07-08 12:33:28 +02:00
2effb3490e minoor changes in responsive behaviour 2021-07-08 12:33:28 +02:00
55672b0288 revamped basic layout and cards 2021-07-08 12:33:28 +02:00
3c5d73027d created separate variable for time delta 2021-06-24 15:41:28 +05:30
d88bdd3ebf corrected filter on no results 2021-06-23 14:15:22 +05:30
5cfe34a5c2 corrected filter working 2021-06-22 19:36:22 +05:30
ad133bc9a3 added cookies for filter effect 2021-06-21 19:57:52 +05:30
8d39b2c4c1 Added content ZIM home button on 404 2021-06-17 12:51:27 +05:30
78083f1f4a Moved OPDS templates under static/templates 2021-06-08 20:37:00 +04:00
dd60235010 Fixed the self link in the output of /catalog/v2/entries 2021-06-08 20:37:00 +04:00
e799f2ff1e OPDSDumper::dumpOPDSFeed() works via mustache
This changes the output of `/catalog/search` as follows:

- Entire search query (rather than only the value of the `q` parameter)
  is put in the <title> node.

- Search performed with an empty query presents itself as "All zims".

- The feed id remains stable for identical searches on the same
  library.
2021-06-08 20:37:00 +04:00
fa42cbc48f Pagination info in /catalog/v2/entries 2021-06-08 20:37:00 +04:00
f886c8c07b Root url is normalized once in the constructor 2021-06-08 20:37:00 +04:00
dfad1c3815 /catalog/v2/searchdescription.xml 2021-06-08 20:37:00 +04:00
07252a127a /catalog/v2/entries is also a search endpoint 2021-06-08 20:37:00 +04:00
19b59fd72f Serving /catalog/v2/entries
/catalog/v2/entries is intended to play the combined role of
/catalog/root.xml and /catalog/search of the old OPDS API. Currently,
the latter role is not yet implemented.

Implementation note: instead of tweaking and reusing
`OPDSDumper::dumpOPDSFeed()`, the generation of the OPDS feed is done via `mustache`
and a new template `static/catalog_v2_entries.xml`.
2021-06-08 20:37:00 +04:00
feeb9f206e /catalog/v2/* XMLs are OPDS 1.2 2021-06-08 20:37:00 +04:00
2e53b51696 Serving /catalog/v2/categories 2021-06-08 20:37:00 +04:00
3c3cf08a1a Serving /catalog/v2/root.xml
Note: This commit somewhat relaxes validation of non variable
`<updated>` elements in the OPDS feed - the contents of any `<updated>`
element is replaced with the YYYY-MM-DDThh:mm:ssZ placeholder.
2021-06-08 16:03:43 +04:00
1ccafe2d97 minor changes in fadeout effect 2021-06-07 15:38:31 +02:00
d6c62b3cd3 corrected spinner and fadeout effect 2021-06-07 15:37:20 +02:00
f39c558d2a added fade out 2021-06-07 15:37:20 +02:00
5b46ad5934 added spinned 2021-06-07 15:37:20 +02:00
49dbd0aa52 fixed reset filters link 2021-06-07 15:37:20 +02:00
179f0faeb1 added minor features 2021-06-07 15:37:20 +02:00
bb92f26b60 added filter functionality 2021-06-07 15:37:20 +02:00
063bb8cd65 added dynamic and subset loading of zim-files in kiwix-serve 2021-06-01 19:33:42 +05:30
3288cd80e5 Render suggestion snippet properly
To render the snippets properly, we need to use the _renderItem property
of the autocomple ui.
2021-05-26 10:53:00 +02:00
2736a46cfe Revert "Kiwix Serve welcome page dynamic and subset loading (OPDS based)" 2021-05-25 17:30:05 +02:00
012973d14a added dynamic and subset loading of zim-files in kiwix-serve 2021-05-25 02:41:12 +05:30
c236f3a32b Check if bookName is available in url parameters
In certain pages like the search result page, bookName is not of the
form `/bookName/endpoint?parameters`. Rather it is available as a query
parameter. From these pages bookName should be assigned from parameters.
2021-05-19 01:12:29 +05:30
5fdc51b23e fixed suggestion system 2021-04-28 14:34:24 +02:00
611146aa37 Added Search Link for bad bookName/articleName on 404 2021-04-12 21:31:47 +05:30
5cb276a933 adding kind and path attributes to suggest response object and using it in autocomplete 2021-04-07 21:04:33 +05:30
c557bb271b injecting root link directly and renamed head_part to head_taskbar 2021-03-24 02:10:16 +05:30
93264f7409 added root functionality for block external link feature 2021-03-23 03:17:14 +05:30
fb26f6b9c5 moved autocomplete from head_part.html to taskbar.js 2021-03-15 18:10:10 +05:30
c7d77395e7 label field of suggestions is also HTML escaped
Without this if the suggestion text contains a double quote, the
response stops being a valid json.
2021-03-04 14:18:58 +01:00
a7fea462b0 HTML decoding of suggestions in the frontend
Since the `value` field of the search suggestion results is HTML
escaped/encoded in the backend (see static/templates/suggestion.json) it
must be decoded in the frontend.
2021-03-04 14:18:58 +01:00
eea10ec3f5 Typo fix in error message 2021-02-09 09:38:18 +01:00
52da58a294 Adjust body padding-top for taskbar
taskbar is placed *above* content using a `padding-top: 3em;` rule
Currently, in regular case, padding-top is too large and leaves ~4/5px between the
taskbar and the content.
This fixes it by using a `calc()` rule to eliminate this extra space
2020-11-04 11:53:59 +00:00
009eb7f905 Added comment marking dependency of a JS variable with warc2zim
warc2zim's service worker captures all requests and then decides what to do based on
availability of the URL in the ZIM or not.
To allow the external URL blocking mechanism, it needs to known whether this was
enabled or not (as those in-iframe links won't be caught).
It detects this by looking for the `window.block_path` variable that is set in the
`block_external.js` script.

As this is fragile, we're adding a comment so that a future maintainer knows that
a third party tools relies on it.
2020-08-19 18:31:46 +02:00
1657b1744c Set fixed size for favicon in home page listing
While [spec](https://wiki.openzim.org/wiki/Metadata#Favicon) says that the favicon
should be a 48x48 image, ZIM creators might not respect it.

If a ZIM contains a larger favicon, the UI is broken. This fixes it ans ensures all
favicon have equal sizes, removing the unpleasing lack of harmony that we can see sometimes.

Note that ZIM will smaller size favicon would get blurry as those would be upscaled.
2020-08-12 14:47:37 +02:00
c74b935a9b added pageLength for search_pagination 2020-08-12 02:08:02 +05:30
0ca27d8edf Add non-minified version of jquery-ui.js
Debian wants to have the source files for minified scripts. Also the
jqueryui.com downloader is broken, so if we ever needed to modify/fix the
library, it would be good to have a non-minified version on hand.

The non-minified version comes from
<https://github.com/components/jqueryui/blob/1.11.0/jquery-ui.js>, which
was the source for the now-deprecated bower package manager.
2020-07-13 16:45:24 +02:00
e32fa28a6c Use python3 instead of python.
`python` binary is not installed on all platform.
But `python3` is (because meson is python3).
And the script we launch is python3 so use the correct version.
2020-05-04 10:52:11 +02:00
fcadacb0ad Resources are compiled as needed
Correct dependencies are set up for resource compilation and
build_always_stale is set to false.
2020-04-28 19:46:14 +04:00