Commit Graph
43 Commits
Author SHA1 Message Date
Henry WilkinsonandIlya Kreymer a4de740999 MKDocs conversion (#278)
Closes #252, Closes #250

## Changes
- ReplayWeb.page uses MKDocs for documentation now!
- Requires both
[`mkdocs-macros`](https://mkdocs-macros-plugin.readthedocs.io/en/latest/)
and [`mkdocs-redirects`]
(https://github.com/mkdocs/mkdocs-redirects) plugins to be installed
- Redirects existing docs pages to their new locations under either
`/embedding` or `/user-guide`
- Unused images have been removed
- Adds new ReplayWeb.page branding!

All pages have received copy edits. All references to future (or
previously) planned features have been removed. More major content
changes of note are as follows:

### Supported Locations
- Made into a page, no longer a table. Locations are either supported or
not listed.

### Offline Use 
- Removes browser cache section, adds improved PWA install and uninstall
instructions.
- Removes navigation instructions to GitHub's releases section in favour
of a link

### Supported Formats
- Moved to the User Guide homepage
- Updated the format support

### Exploring Archives
- Example links for showcasing features have been moved to their
respective feature documentation section on this page

### Remove Usage, Examples, and Troubleshooting Pages
- Usage content is covered in the user guide index
- Troubleshooting content has been added to a question section on the
getting started page about WARC vs WACZ.
- Examples are now Featured Projects on the docs homepage!

### Build Process
- Removes Jekyll & related site assets.
- Adds new GitHub action for publishing
- Adds a python macro to dynamically load the replayweb.page version from package.json
- Relocates replayweb.page site content under /site (including docs)
- Some assets (favicon, logo) and sw.js/ui.js automatically copied into /site

---------
Co-authored-by: Ilya Kreymer <ikreymer@gmail.com>
2024-04-07 11:07:02 -07:00
Emma Segal-Grossman a63390f10c Update NPM packaging, linting, and a bunch of types (#275)
Preparation for
https://github.com/webrecorder/archiveweb.page/issues/198 /
https://github.com/webrecorder/archiveweb.page/pull/199.

## Changes

- Organizes published files more cleanly, using `dist/types` folder as
the target for type declarations and sourcemaps
- Configures type field in `package.json`
- Updates ESLint & its config
  - Sets up type-informed linting rules mirroring browsertrix
- Adds a bunch of other useful eslint and eslint-typescript rules, and
applies auto-fixes to the codebase
- Cleans up a bunch of types throughout the codebase, particularly parts
of the code used by ArchiveWebPage
- Changes `ItemIndex#_deleting` from `private` to `protected` so that a
part of AWP that extends it can do so properly
- Makes a bunch of previously-implied [non-null
assertions](https://www.typescriptlang.org/docs/handbook/2/everyday-types.html#non-null-assertion-operator-postfix-)
explicit
- Updates `URLResource` and `ItemType` types (and renames `Item` →
`ItemType` to disambiguate from the `Item` class)
- Removes `node-sass` and replaces it with `sass-embedded` for much
quicker installs and compilation
2024-02-06 18:50:12 -08:00
sua yooandemma 03fefc85a5 Migrate electron files to typescript (#267)
- Switches electron src files to typescript with minimum typing required
for build
- Adds webpack-merge for shared typescript build config and jsdoc types
- Minor README changes

---------

Co-authored-by: emma <hi@emma.cafe>
2023-11-29 15:53:48 -05:00
emma e9438eb724 improve typescript and linting usage across codebase
add ts-lit-plugin and eslint-typescript

disable no-invalid-css rule

fix a bunch of errors raised by eslint and typescript

run prettier & eslint on the remaining files

remove unused imports

split coll-index into index and info components...
and rename "coll" -> "item" for these.
also includes some fixes for previously-undocumented properties used on
non-ts elements.

extract labeled fields into separate component...
and make a few type improvements too

swap custom copy button for shoelace one

rename a few more missed things
2023-11-29 15:53:46 -05:00
sua yoo 22313c5bb1 Build Webpack in Pages workflow (#222) 2023-09-05 17:26:14 -07:00
sua yoo 2d0b163148 Upgrade Lit to 2.8 and add Shoelace styles (#206) 2023-09-05 17:25:42 -07:00
sua yoo b7406189bb Add Typescript to build (#207) 2023-09-05 17:24:08 -07:00
Ilya Kreymer 2bc9fb0a15 Use published sw.js from wabac.js instead of rebuilding a custom version. (#223)
* sw: instead of rebuilding sw.js with slightly different settings (baked in index.html + ruffle.js cache),
can now just use the published sw.js release with custom queryArgs, injectScripts=ruffle/ruffle.js
index.html is cached automatically on-load
webpack: for dev server, still build 'sw.js' locally to allow dynamic updates when developing on a linked wabac.js
remove src/sw.js, as no longer used, just importing from wabac.js directly
bump to 1.8.9
2023-08-28 19:59:29 -07:00
Ilya Kreymer 0c737101c2 loading + fidelity fix:
- loading: Support loading URLs without extension (including blob: urls), automated type detection of WACZ, WARC, compressed and uncompressed (via wabac.js)
 - fidelity: Improved handling of ESM modules, cookies, Vimeo videos (via wabac.js)
 - dependencies: Update to wabac.js 2.15.0, wombat 3.4.3
bump to 1.7.11
2023-01-15 11:17:06 -08:00
Ilya Kreymer 7d0866aa23 deps: update to wabac.js 2.14.0 (#143)
deps: also includes update to wombat 3.4.2, warcio 2.0.1
ci: fix yarn flags, add --ignore-engines to electron build
build: update banner copyright text to use current year
fidelity fixes:  including better location and ESM module rewriting (via wabac.js and wombat)
reduce size of sw.js by ~40k
bump to 1.7.9
2022-12-17 10:39:19 -08:00
Ilya Kreymer e6f837df13 Cleanup Electron App + Dependency Update (#139)
* electron: clean-up / remove unused code in main process, including:
- remove native plugin init (no longer supported)
- remove auto-js-ipfs (used in render process)
- remove ipfs handling logic (handled in render process)
- use custom file2:// scheme for loading files, instead of custom prefix
- proxyLive supports POST requests, using original UA (if set, for archiveweb.page)
- webpack: remove unused __IPFS_CORE_URL__
- ci: add lint check

* dependency update:
- update to wabac.js 2.13.15 for latest auto-js-ipfs (2.1.0) and wombat (3.3.13)
- update to electron 22.0
- update webpack + electron updater to latest

* bump to 1.7.8
2022-12-07 13:33:36 -08:00
RangerMauveandIlya Kreymer f1df02ea3c remove js-ipfs in electron app, eslint to dev deps (#123)
- add ipfs:// protocol handlers, not enabled for now
- use browser-side auto-js-ipfs for loading from ipfs even in electron app
- deps: bump wabac.js to 2.13.0
- update CHANGES

Co-authored-by: Ilya Kreymer <ikreymer@gmail.com>
2022-10-04 15:54:43 -07:00
Ilya Kreymer 114d5fe1c9 gh action: update action version
dependency: update lit to latest
dependency: rollback ipfs-core update, as electron-builder does not yet support node>=15
2022-01-09 10:17:52 -08:00
Ilya Kreymer 91ef718b08 dependency update release: update to wabac.js 2.10.0, wombat 3.3.6, electron 16.0.6, ruffle (2022-01-08)
bump to 1.5.7
2022-01-08 23:33:33 -08:00
Ilya Kreymer 178d0507eb * large WARC loading optimizations (attempted to fix #67)
- use dedicated web worker for loading, remove when done
- update to warcio 1.5.0 for faster loading of large WARCs
- show WARC records loading for better progress update

* fidelity: fix potentially invalid location redirect via wombat 3.3.5 (see: webrecorder/pywb#684)

* dependencies: wabac.js 2.10.0-beta.0 (includes warcio 1.5.0, wombat 3.3.5)

* bump to 1.5.6, update CHANGES
2021-11-27 17:06:37 -08:00
Ilya Kreymer a261a61721 fidelity: fix eval edge case (via wombat), enable http->https check for wacz sources (via wabac.js)
dependency updates:
- switch to webpack 5 and related build dependencies
- update litelement -> 'lit'
- wabac.js 2.9.2, wombat 1.3.4

search:
- update to latest flexsearch
- optimize search by using single-field index

bump to 1.5.3
2021-09-18 12:32:00 -07:00
Ilya Kreymer d341c03350 ipfs improvements:
- fix ipfs for apple m1 osx builds by adding extra binary prebuilds (for now)
- use <profile directory>/js-ipfs for ipfs repo
- update to js-ipfs 0.10.6
bump to 1.5.2
2021-09-13 07:31:37 -07:00
Ilya Kreymer 14bcd4aaf2 build fix:
- fix universal build for osx using workaround
- fix including ruffle, add to build files list, instead of to dist/
2021-08-29 13:43:51 -07:00
Ilya Kreymer c090003d8a update to wabac.js 2.9.0-beta.0, smaller file size, loading improvements
ruffle: support for ruffle for flash loading, both hosted and in app
electron: update to latest beta (14) for latest chromium version
embed error messages: better error message when service worker can not be found
electron: build universal app for osx
bump to 1.5.0!
2021-08-28 13:55:57 -07:00
Ilya Kreymer fa0b229aa9 loading: fix loading from ipfs, use latest ipfs-core
fidelity: support local/sessionStorage replay, if available
update CHANGES
dep: use wabac.js 2.7.8
bump to 1.4.5
2021-06-05 21:44:46 -07:00
Ilya Kreymer 0ef8f955db 1.4.0 Release (#45)
* customizations for chooser, coll-index and appmain to support usage in archiveweb.page
- chooser: support panel/message view
- move apiPrefix to misc
- make coll-index extensible, overridable styles, filtering

* api changes: make configurable in coll-index, now using '/w/' instead of '/wabac/', '/c/' prefix for coll apis

* lint pass!

* bulma: update to 0.9.2, fix delete spinner with latest bulma

* ui fixes:
- show 'Loading Archives...' on initial load until first api response succeeds
- fix typo in oncontrollerchange not actually resolving the promise!

* embed sandbox: add other allow options, except top-nav
- first api load: keep loading message until first successful api load
- don't reset hash on purge to keep current page
- sw config: fix typo with latest wabac.js
- embed: add 'noSandbox' option to avoid adding sandbox to iframe, needed to show PDFs, add more allow rules (all except top-navigation)

* ui improvements:
- refresh: ensure location refresh from hitting enter in location bar always resets url
- pageentry doubleclick: ensure double-clicking on page in sidebar always triggers reload, even if current page
- pageentry typo fix: fix missing var causing selection error (fixes webrecorder/archivewebpage#25)
- lint: don't include 'event' as global
- use latest wabac.js 2.7.0-beta.1

* add CHANGES for 1.4.0, add 'noSandbox' to embedding options
- electron app: fix path to 'w/'
- bump electron to 11.4.3

* docs: autoload current version from package.json
- chooser: support .json files for multiwacz (experimental)
- update CHANGES.md
- add missing .eslintrc.js file

* bump version to 1.4.0
2021-04-25 16:45:40 -07:00
Ilya Kreymer b36726535a update to wabac.js 2.5.6
text fixes: update copyright, CHANGES.md
2021-01-28 16:04:51 -08:00
Ilya Kreymer c08c80bd98 dependencies: update to wabac.js 2.5.5 + wombat 3.0.4
update CHANGES
2021-01-28 13:43:34 -08:00
Ilya Kreymer f6de8dfaf0 library support improvements: add index.js which exports all from ui.js
update to latest wabac.js -- smaller size
support for 'source' param on <replay-app-main> which sets sourceUrl and forces direct loading of a single archive only
bump version to 1.3.5
2020-12-13 00:18:55 -08:00
Ilya Kreymer cd40979625 app: ipfs loading improvements:
use IPFSClient from wabac.js
app: remove # from ipfs paths sent to app
preload interface made more extensible
2020-12-09 22:46:16 -08:00
Ilya Kreymer 40c2e937dc ui improvements:
- condense navbar, always show with breadcrumbs for collection title and current page
- add update-title event to propagate replay page title for breadcrumb, also updates document.title
- appmain: make app component more extensible, make coll-index also extensible with custom coll info component
- condense index view headers
- bump to 1.3.2
2020-12-07 22:37:08 -08:00
Ilya Kreymer 228e9bdff6 IPFS Support + Loading Improvements (Better local file handling) + Streamlined Collection View (#25)
* support ipfs:// urls!
misc: better error message for loading from http://
tabs: don't render pages/story/urls if hidden

* ipfs work: remove ww only use sw

* electron + ipfs: add ipfs support to electron app, using ipfs-core
- route ipfs requests to files proxy with 'ipfs=' query param

* file loading:
- add support for new Chrome native file system api with file handles, which allows persistent access to files vial file handles
- if window.showOpenFilePicker() is available use that, include file handle in load message
- support asking permissions for file handles, using similar workflow as google drive auth
- attempt to ask for file permission directly, show auth button if fails (user gestured required)
- replace auth modal with iframe replacement insert to ask for auth for google drive and local file

* ui overhaul for 1.3.0 / condense collection view:
- don't show navbar in collection view
- add logo to back to home page to location bar
- condense location bar buttons
- convert terms to general about dialog, available from collection context menu
- add info tab to collection view in place of drop-down info
- make <wr-coll-info> component, used in both collection list and info tab with additional details
- update to wabac.js 2.2.0

* update CHANGES.md
2020-11-16 18:31:15 -08:00
Ilya Kreymer 0f58a881a2 licenses: move copyright to COPYRIGHT, add AGPL LICENSE, ensure banner added to all webpack built files
update to latest wabac.js
2020-11-02 21:17:01 -08:00
Ilya Kreymer e12407983c electron app:
- add file association for .wacz
- support opening wacz, warc, har files via double-click from os (fixes #24)
- command line: support opening files via command line, as well as specifying --url and --ts
- support cmdline args via 'yarn run start-electron <file> --url <url> --ts <ts>'
2020-10-25 09:04:40 -07:00
Ilya Kreymer 557b528ca6 build: disable automatic chunking for now 2020-08-31 19:40:04 -07:00
Ilya Kreymer a330c2c5c2 update to latest wabac.js -- fix reading small wacz files
embed fixes: fix 'replayonly' mode to hide locationbar
embed loading screen: simplify, don't show cancel button, filename
bump to electron 10.0.0
bump to beta.1
2020-08-24 23:09:18 -07:00
Ilya Kreymer b9a4089c6b license / docs pass:
- add new docs for loading, exploring, sharing, embedding, and offline usage
- add license file / license banner

electron app:
- for now, don't bundle docs, open in native browser

embeds:
- support 'embed' option, 'replayonly' or 'full' (default if no url)

ui:
- display package.json version in info menu

package.json:
- update scripts to match README
- move electron entrypoint into extraMetadata
- add scripts for packaging as module

README: minor edits
2020-06-11 00:42:10 -07:00
Ilya Kreymer 335c2bfd35 electron app: send filename in query filename= param, instead of as part of url path, more robust and should work on windows 2020-06-09 18:58:17 -07:00
Ilya Kreymer 03023523b7 big ui update, page search + full text
- split file chooser from coll index, insert as header, make file chooser collapsible
- revamp collection index to be responsive
- add separate sorter component, used for collection index and pages
- combine 'curated lists' + pages, with page search + narrative
- ensure page + narrative lists are collapsible
- page search: support title, url and full text search if available, using flexsearch
- page search: keyword highlighting, load all pages, showing in increments of 100
- page and resource search: delay search to 1/4 sec of inactivity to avoid too many queries
- electron app: ensure noCache is set to true for local files
- embedding: remove separate embed.js, just use ui.js for embed as well
- embedding: support embedding iframe in a local origin with just sw.js and ui.js: sw.js serves index.html,
<replay-web-page> embed injects ui.js into iframe
- sw.js, new service worker entry point
- sw and ww inited only from <replay-app-main>, ui.js loaded from <replay-web-page> embed component
2020-05-26 14:43:28 -07:00
Ilya Kreymer e3d5abdbeb refactor: split frontend into file per component! 2020-05-22 23:43:56 -07:00
Ilya Kreymer 220d14aea3 jekyll: move jekyll back to root, but simpler setup, exclude via _config.yml
app: bundle jekyll docs into app, add 'yarn run docs' to build
ui: add back/forward arrows for app only, adjust responsiveness for app, add IS_APP flag injected via preload
ui: add animated logo, friendly message on empty replay frame
app: improve serve logic:
- serve static files from static root
- serve replay from http localhost instead to avoid proxying https for remote requests
- serve local lookup from http prefix also
- catch any fallthrough from replay as 404
- add timestamp to response channels to ensure uniqness
2020-05-21 18:49:26 -07:00
Ilya Kreymer da1e5c03df reorg dir structure:
- keep shared and electron build at root
- move static files for replayweb.page and Jekyll config to docs/
- move Jekyll markdown to docs/docs/
2020-05-20 17:28:03 -07:00
Ilya Kreymer 1a2f2c00a2 add electron build!
- use webpack to build electron-main and electron-preload
- intercept 'https' protocol to run on 'https://replayweb.page' in app
- serve local files from 'https://files.replayweb.page'
- support flash in with service worker replay: catch any fallthrough urls and load via intercept with render process callback
- add icons for electron build
2020-05-19 22:49:08 -07:00
Ilya Kreymer 077c8cae19 bundle into single js file!
- remove external css - ensure bulma styles don't rely on html, body
- move logo.svg to be loaded inline
- rename scss -> assets
- remove wombat/wombatWorkers, bundled via raw-loader and sw.js
2020-05-16 09:34:49 -07:00
Ilya Kreymer 780d5b74a9 add embed.js for embedding <replay-web-page>!
css tweaks for replay iframe, initial support embed param to hide nav bar
various css tweaks for scrolling!
2020-05-11 19:10:09 -07:00
Ilya Kreymer 1a4793eefa css optimization: bundle bulma, main.scss as inline css injected directly into lit-element css
import a subset of bulma to decrease size in main.scss
import only base bulma for outer html page in base.scss
2020-05-03 14:57:51 -07:00
Ilya Kreymer 6f04588dfd add CNAME, add examples from wabac.js, build directly from wabac.js 2020-05-02 13:27:17 -07:00
Ilya Kreymer e023726fd2 split off from wabac.js:
- add pageembeds.js for now
- new webpack build, use /sw.js in prod, /dist/sw.js in dev to work with webpack-dev-server single directory
- add wombat dependency and webpack build
2020-05-02 11:27:48 -07:00