Commit Graph

7253 Commits (dbfe5cadf4ca1f987942fbc888e9607c79ce3a59)

Author SHA1 Message Date
Richard Hansen 71dfa7070d deps: Update ueberdb2 to get metrics 2021-03-08 22:32:39 +00:00
Richard Hansen 926f0fcefb CSS: Increase size of contenteditable area 2021-03-08 14:39:18 +00:00
Richard Hansen 404486069c ace: Build the outer and inner iframes programmatically
This makes the code easier to read and it silences Chrome's
`document.write()` warning:
https://developers.google.com/web/updates/2016/08/removing-document-write

This is a redo of commit a17f9bf3cf,
which was reverted in commit 912f0f195f
due to a CSS bug.
2021-03-05 19:31:59 +00:00
webzwo0i 4ca989a255
sessions: add more endpoints that do not need a session (#4921)
* add more endpoints that do not need a session

* Update src/node/hooks/express/webaccess.js

Co-authored-by: Richard Hansen <rhansen@rhansen.org>

* Update src/node/hooks/express/webaccess.js

Co-authored-by: Richard Hansen <rhansen@rhansen.org>

Co-authored-by: John McLear <john@mclear.co.uk>
Co-authored-by: Richard Hansen <rhansen@rhansen.org>
2021-03-05 07:48:33 +00:00
Richard Hansen 60da2373a6 CSS: Add comment to `no-skin/pad.css` to silence warning
Firefox prints "Style sheet could not be loaded" if the file is empty.
2021-03-05 07:45:48 +00:00
Richard Hansen 5546cc5e7b CSS: Delete bogus `<link>` tag
Browsers report an error with this tag. Strangely, this tag has
existed since Etherpad's very first commit.
2021-03-05 07:45:48 +00:00
Richard Hansen 470f40d7db CSS: Use `auto` for iframe body height
This change makes no visual difference right now, but will matter (for
reasons I don't understand) once we change `ace.js` to build the
iframes by constructing elements in JavaScript (vs. writing HTML).
2021-03-05 07:45:48 +00:00
Richard Hansen 48e1d1c23f CSS: Fix class name for outer iframe `<html>` tag
* Add the class "pad" to the `<html>` tag in `pad.html` (the outer
    iframe's parent).
  * Change the CSS selector that refers to the `<html>` tag in
    `pad.html` from `html:not(.inner-editor)` to `html.pad`.
  * Change the class name of the outer iframe's `<html>` tag from
    "inner-editor" to "outer-editor".
  * Update CSS rules to use the new class name.
2021-03-05 07:45:48 +00:00
John McLear 6615d36f8d
Merge branch 'master' into develop 2021-03-05 07:28:48 +00:00
John McLear b99c2cae22
Merge branch 'develop' 2021-03-05 07:28:47 +00:00
John McLear de394f72a6
bump version 2021-03-05 07:28:44 +00:00
John McLear dabb4917ed
changelog 1.8.12 2021-03-05 07:27:31 +00:00
John McLear 5ac90ab30f tests: Allow time for minification to complete
Minification happens after the initial visit and request to pages.
2021-03-05 07:11:42 +00:00
John McLear 536db7553f
tests: CI of updating from master > this commit. (#4912)
* tests: CI of updating from master > this commit.

In response to cypress eslint I thought I'd put some CI testing for if a PR might break automated upgrading.

Matrix usage is probably overkill.

* Update major-version-git-pull-update.yml

* Name...

* include a front end test

* fix pathing

* Clarity on what's happening

* Update .github/workflows/major-version-git-pull-update.yml

Co-authored-by: Richard Hansen <rhansen@rhansen.org>

* Update .github/workflows/major-version-git-pull-update.yml

Co-authored-by: Richard Hansen <rhansen@rhansen.org>

* Update .github/workflows/major-version-git-pull-update.yml

Co-authored-by: Richard Hansen <rhansen@rhansen.org>

Co-authored-by: Richard Hansen <rhansen@rhansen.org>
2021-03-05 06:38:50 +00:00
snyk-bot d0e257d8df fix: upgrade resolve from 1.19.0 to 1.20.0
Snyk has created this PR to upgrade resolve from 1.19.0 to 1.20.0.

See this package in npm:
https://www.npmjs.com/package/resolve

See this project in Snyk:
https://app.snyk.io/org/johnmclear/project/d9a12bfb-7ccd-443f-9e22-f30d339cc8c5?utm_source=github&utm_medium=upgrade-pr
2021-03-05 06:37:45 +00:00
Richard Hansen eccec0ba0a Docker: Invoke npm only once when installing plugins
This speeds up the build process.
2021-03-04 19:07:03 +00:00
Richard Hansen c07bfe10bd Docker: Add arg for the Etherpad directory
This makes it possible for users to match the directory inside the
container to the host system (for convenience or to avoid confusion).
2021-03-04 19:07:03 +00:00
Richard Hansen 34d9069874 Docker: Add args for the etherpad user's home, UID, GID, and shell
Now one can create an `etherpad` user and group on the host system and
set the container's UID and GID to match:

    adduser --system --group etherpad &&
    uid=$(id -u etherpad) &&
    gid=$(id -g etherpad) &&
    docker build --build-arg EP_UID="${uid}" --build-arg EP_GID="${gid}" .

This ensures that files created by user `etherpad` inside the
container are owned by user `etherpad` outside the container.
2021-03-04 19:07:03 +00:00
translatewiki.net 21cdf0edaa Localisation updates from https://translatewiki.net. 2021-03-04 13:58:49 +01:00
Richard Hansen 912f0f195f Revert "ace: Build the outer and inner iframes programmatically"
This reverts commit a17f9bf3cf, which
caused a mysterious bug with the line numbers. Revert to avoid
blocking a new release while I figure out the bug.
2021-03-04 02:05:54 +00:00
Richard Hansen 0aad3b74da pluginfw: Improve rendering of hook list
There are two main benefits:
  * HTML is no longer printed in the startup debug logs.
  * `require()` is no longer called on client-side files. This
    eliminates "Failed to load <file> for <plugin>: ReferenceError:
    window is not defined" errors when users visit
    `/admin/plugins/info`.
2021-03-03 11:19:37 +00:00
Richard Hansen 7e698baa80 pluginfw: Improve hook function load error message 2021-03-03 11:19:37 +00:00
John McLear f95b09e0b6
Import: Import don't show warnings for supported elements 2021-03-02 17:14:47 +00:00
John McLear f24353e806
Update README.md 2021-03-02 07:00:05 +00:00
John McLear 05b27cfd5d
Update README.md 2021-03-02 06:54:08 +00:00
snyk-bot 2fd06535b7 fix: upgrade express-rate-limit from 5.2.3 to 5.2.5
Snyk has created this PR to upgrade express-rate-limit from 5.2.3 to 5.2.5.

See this package in npm:
https://www.npmjs.com/package/express-rate-limit

See this project in Snyk:
https://app.snyk.io/org/johnmclear/project/d9a12bfb-7ccd-443f-9e22-f30d339cc8c5?utm_source=github&utm_medium=upgrade-pr
2021-03-02 06:52:15 +00:00
Richard Hansen 797ffa5600 Minify: Avoid `path.relative()`
Constructing a relative pathname on Windows is problematic because the
two absolute pathnames might be on different drives (or UNC paths).
Use `path.resolve()` instead of `path.join()` where appropriate to
avoid the need to construct a relative path.
2021-03-02 06:20:10 +00:00
Richard Hansen 8971166c58 lint: Set up Cypress config and fix issues 2021-03-02 05:49:48 +00:00
John McLear a79f9efdb4
Include props to Sauce Labs for the tests they power. (#4897)
* Include props to Sauce Labs for the tests they power.

* include message in CI
2021-03-01 14:46:50 +00:00
Richard Hansen b0862cd030 ace: Delete all `$$INCLUDE_CSS` logic
The intention of the deleted code was to reduce the number of fetches,
but it only saved a single fetch due to implementation flaws. The
right way to reduce the number of fetches is to use a bundling
technology such as webpack, and this change makes it easier to do so.
2021-03-01 14:32:33 +00:00
Richard Hansen 66d3ac3783 ace: Debug logging 2021-03-01 14:32:33 +00:00
Richard Hansen a17f9bf3cf ace: Build the outer and inner iframes programmatically
This makes the code easier to read and it silences Chrome's
`document.write()` warning:
https://developers.google.com/web/updates/2016/08/removing-document-write
2021-03-01 14:32:33 +00:00
Richard Hansen c696732838 ace: Asyncify `Ace2Editor.init()` 2021-03-01 14:32:33 +00:00
Richard Hansen 159fd5bdeb ace: Simplify passing of `editorInfo` 2021-03-01 14:32:33 +00:00
Richard Hansen e57829183d ace: Pass objects to Ace2Inner via function args 2021-03-01 14:32:33 +00:00
Richard Hansen 6fe0154129 ace: Use absolute URLs when building iframes
This isn't strictly necessary right now, but will become
necessary (due to a Safari quirk) when we change to building the
iframes programmatically (vs. the current `document.write()`
approach).
2021-03-01 14:32:33 +00:00
Richard Hansen 9cfc2fb801 ace: Simplify the `aceEditorCSS` hook map function 2021-03-01 14:32:33 +00:00
Richard Hansen 94c221586c ace: Factor out duplicated `$$INCLUDE_CSS` code 2021-03-01 14:32:33 +00:00
Richard Hansen 54df7f3728 ace: Delete unused `clientVars.disableCustomScriptsAndStyles` 2021-03-01 14:32:33 +00:00
Richard Hansen d84447290e ace: Delete unnecessary IIFE 2021-03-01 14:32:33 +00:00
Richard Hansen 3a311d2182 ace: Lint and simplify script strings 2021-03-01 14:32:33 +00:00
Richard Hansen c9b1f17f25 ace: Format script strings for readability 2021-03-01 14:32:33 +00:00
Richard Hansen b3416c4eeb ace: Delete ignored class attribute 2021-03-01 14:32:33 +00:00
Richard Hansen c9c8b27854 ace: Delete unused `Ace2Editor.getFrame()` method 2021-03-01 14:32:33 +00:00
John McLear 64e9e7fcda
tests: Frontend test Windows ZIP (#4894)
* tests:  Frontend test Windows ZIP

This PR introduces Frontend testing within Github actions!

We're depending a lot on saucelabs recently and that's fine but sometimes we just want to quickly do a frontend simple test on a weird environment (IE windows build) so this PR solves that problem.

Things to note.

    It still builds the windows .zip if the cypress tests fail.
    It does not add any heavy deps to Etherpad as cypress must be installed in CI.
    Cypress is responsible for running the Etherpad instance.

It's up to us how much we use this or not, I know it introduces a bunch of technical debt but I tried to keep that a minimum by compartmentalizing things and documenting where required.

* Update .github/workflows/windows-zip.yml

Co-authored-by: Richard Hansen <rhansen@rhansen.org>

* remove timeouts

* Move folder structure up a level

* Update windows-zip.yml

* Update test.js

Co-authored-by: Richard Hansen <rhansen@rhansen.org>
2021-03-01 14:31:55 +00:00
John McLear b0f16bb1f1 Use stable sauce version 2021-03-01 13:08:34 +00:00
John McLear b3d7f5d63e pluginTools: stalePlugins.js
Outputs a list of pluginnames and email address for maintainers to contact.  Useful for me to bump folks to maintain there stuff and stop it getting stale :)
2021-02-28 16:05:53 +00:00
John McLear 35ae08ca77
tests: run a long(1+ hr) load test 2021-02-28 16:05:16 +00:00
John McLear d7fd3934de
Merge branch 'develop' of github.com:ether/etherpad-lite into develop 2021-02-28 15:51:51 +00:00
John McLear 237bab7e3e
branding: change etherpad lite to etherpad in Pad settings modal 2021-02-28 15:51:39 +00:00