Commit Graph

85 Commits (8f83f7905723ef739bc577be3c8dfb5a9e1e0c0a)

Author SHA1 Message Date
Barış Soner Uşaklı 1928a18617 fix: , fix webinstaller folders
Barış Soner Uşaklı d20b07cfea
Webpack5 ()
* feat: webpack 5 part 1

* fix: gruntfile fixes

* fix: fix taskbar warning

add app.importScript
copy public/src/modules to build folder

* refactor: remove commented old code

* feat: reenable admin

* fix: acp settings pages, fix sortable on manage categories

embedded require in html not allowed

* fix: bundle serialize/deserizeli so plugins dont break

* test: fixe util tests

* test: fix require path

* test: more test fixes

* test: require correct utils module

* test: require correct utils

* test: log stack

* test: fix db require blowing up tests

* test: move and disable bundle test

* refactor: add aliases

* test: disable testing route

* fix: move webpack modules necessary for build, into `dependencies`

* test: fix one more test

remove 500-embed.tpl

* fix: restore use of assets/nodebb.min.js, at least for now

* fix: remove unnecessary line break

* fix: point to proper ACP bundle

* test: maybe fix build test

* test: composer

* refactor: dont need dist

* refactor: more cleanup

use everything from build/public folder

* get rid of conditional import in app.js

* fix: ace

* refactor: cropper alias

* test: lint and test fixes

* lint: fix

* refactor: rename function to app.require

* refactor: go back to using app.require

* chore: use github branch

* chore: use webpack branch

* feat: webpack webinstaller

* feat: add chunkFile name with contenthash

* refactor: move hooks to top

* refactor: get rid of template500Function

* fix(deps): use webpack5 branch of 2factor plugin

* chore: tagging v2.0.0-beta.0 pre-release version 💥 :shipit: 🎉 🚀

* refactor: disable cache on templates

loadTemplate is called once by benchpress and the result is cache internally

* refactor: add server side helpers.js

* feat: deprecate /plugins shorthand route, closes 

* refactor: use build/public for webpack

* test: fix filename

* fix: more specific selector

* lint: ignore

* refactor: fix comments

* test: add debug for random failing test

* refactor: cleanup

remove test page, remove dupe functions in utils.common

* lint: use relative path  for now

* chore: bump prerelease version

* feat: add translateKeys

* fix: optional params

* fix: get rid of extra timeago files

* refactor: cleanup, require timeago locale earlier

remove translator.prepareDOM, it is in header.tpl html tag

* refactor: privileges system to use a Map in the backend instead of separate objects for keys and labels ()

* refactor: privileges system to use a Map in the backend instead of separate objects for keys and labels

- Existing hooks are preserved (to be deprecated at a later date, possibly)
- New init hooks are called on NodeBB start, and provide a one-stop shop to add new privileges, instead of having to add to four different hooks

* docs: fix typo in comment

* test: spec changes

* refactor: privileges system to use a Map in the backend instead of separate objects for keys and labels ()

* refactor: privileges system to use a Map in the backend instead of separate objects for keys and labels

- Existing hooks are preserved (to be deprecated at a later date, possibly)
- New init hooks are called on NodeBB start, and provide a one-stop shop to add new privileges, instead of having to add to four different hooks

* docs: fix typo in comment

* test: spec changes

* feat: allow app.require('bootbox'/'benchpressjs')

* refactor: require server side utils

* test: jquery ready

* change istaller to use build/public

* test: use document.addEventListener

* refactor: closes 

* refactor: generateTopicClass

* fix: column counts for other privileges

* fix: , regression where sorted-list items did not render into the DOM in the predicted order [breaking]

* fix: typo in hook name

* refactor: introduce a generic autocomplete.init() method that can be called to add nodebb-style autocompletion but using different data sources (e.g. not user/groups/tags)

* fix: crash if `delay` not passed in (as it cannot be destructured)

* refactor: replace substr

* feat: set --panel-offset style in html element based on stored value in localStorage

* refactor: addDropupHandler() logic to be less naive

- Take into account height of the menu
- Don't apply dropUp logic if there's nothing in the dropdown
- Remove 'hidden' class (added by default in Persona for post tools) when menu items are added

closes 

* refactor: simplify utils.params [breaking]

Retrospective analysis of the usage of this method suggests that the options passed in are superfluous, and that only `url` is required. Using a browser built-in makes more sense to accomplish what this method sets out to do.

* feat: add support for returning full URLSearchParams for utils.params

* fix: utils.params() fallback handling

* fix: default empty obj for params()

* fix: remove \'loggedin\' and \'register\' qs parameters once they have been used, delay invocation of messages until ajaxify.end

* fix: utils.params() not allowing relative paths to be passed in

* refactor(DRY): new assertPasswordValidity utils method

* fix: incorrect error message returned on insufficient privilege on flag edit

* fix: read/update/delete access to flags API should be limited for moderators to only post flags in categories they moderate

- added failing tests and patched up middleware.assert.flags to fix

* refactor: flag api v3 tests to create new post and flags on every round

* fix: missing error:no-flag language key

* refactor: flags.canView to check flag existence, simplify middleware.assert.flag

* feat: flag deletion API endpoint, 

* feat: UI for flag deletion, closes 

* chore: update plugin versions

* chore: up emoji

* chore: update markdown

* chore: up emoji-android

* fix: regression caused by utils.params() refactor, supports arrays and pipes all values through utils.toType, adjusts tests to type check

Co-authored-by: Julian Lam <julian@nodebb.org>
Barış Soner Uşaklı 997ab7d416 fix: , remove logging of env vars
Barış Soner Uşaklı 6b22d0e15f fix: , use the correct env vars for web install
Julian Lam 6e156daaf6 fix: don't load setup.json into nconf if setup.json doesn't exist
Barış Soner Uşaklı 14bc83a88e refactor: less.render returns promise
Julian Lam 16e0bca570 fix: improper use of filename extensions
Peter Jaszkowiak 5c2f0f0557 chore: eslint no-restricted-syntax
Peter Jaszkowiak dab3b23575 chore: eslint no-var, vars-on-top
Peter Jaszkowiak b56d9e12b5 chore: eslint prefer-arrow-callback
Peter Jaszkowiak 707b55b6a5 chore: eslint prefer-template
Peter Jaszkowiak 4ee0f1459d chore: eslint import/newline-after-import
Peter Jaszkowiak dad01e3051 chore: eslint no-bitwise
Peter Jaszkowiak d30ea25629
feat(deps): benchpressjs@2.2.1 ()
Better warnings, faster template compiles
Peter Jaszkowiak de5a21f19b
fix(): web install templates now compiled ()
Barış Soner Uşaklı 3881ac309f refactor: async/await install/web.js
Barış Soner Uşaklı dc29f4dca2 refactor: switch to using slugify module
Billy Ohgren 89062d8e70
add filename to less render call ()
Barış Soner Uşaklı e80379dc0e feat: display stack trace on winston.error
Barış Soner Uşaklı 4bc77d064b feat: disable timeout on launch route
Andrew Rodrigues 962b7f73d3 fix:
Barış Soner Uşaklı f4df89fe90 closes
Barış Soner Uşaklı 85c60316ed
upgrade to winston 3.1, closes ()
* upgrade to winston 3.1

* fix winston in web/install and tests
Ben Lubar 33228bb7fe PostgreSQL database driver ()
* [test/database/list] Fix test list 4 being used in two different tests

* [database/postgres] PostgreSQL database driver

* [database/postgres] Make transactions work based on continuation scope.

* [database/postgres] Implement nested transactions

* eslint --fix

* Add database changes from earlier this week to the PostgreSQL driver.

* Fix typo

* Fix postgres.incrObjectFieldBy returning undefined instead of null when given NaN

* [database/postgres] Fix sortedSetsCard returning an array of strings.

* Update socket.io postgres adapter

* Fix PostgreSQL erroring when multiple updates are made to the same sorted set entry in a single operation.

Add a test case to catch this error.

* Fix lint errors.

* Only prune sessions on one instance in a cluster to avoid deadlocks.

They're caught and handled by the database server, but they spam the logs.

* Fix arguments.slice.
Barış Soner Uşaklı fc56347c22 closes
Barış Soner Uşaklı 085034a103 store success error for page reloads
Barış Soner Uşaklı c2f088cb61 dont install multiple times
Julian Lam 943d33ed09 closes , also fixed issue with type: 'literal' in config.json
Peter Jaszkowiak a00f1f9a81 Use uglify-es for ES6 support ()
Julian Lam da328662c5 don't flatten arrays, stringify them, in installer
Barış Soner Uşaklı fbed4c056e show env vars passed to setup
Julian Lam 1d42d1a6d2 moving expected location of setup.json to root
Julian Lam 741693bc1f closes
Barış Soner Uşaklı 3b3a28dc15 add ping routes to webinstaller
Barış Soner Uşaklı 82f2025944 disable timeout on post install route
Barış Soner Uşaklı e092778ba6 closes
Peter Jaszkowiak dbdc05404d Use console.log instead of process.stdout.write ()
* Use console.log instead of process.stdout.write

* Don't break the installer
Peter Jaszkowiak c731661a39 Remove external sources from installer page ()
* Remove external sources from installer page

* Remove bootstrap.min.css

* Make spinner display consistently cross-platform

* Change spinner to look better
Baris Usakli 5ca3b535e7 closes
Julian Lam 158e47e2ac linting
Peter Jaszkowiak 2ca1475eee Fix web installer benchpress issue
Peter Jaszkowiak abffc29128 Use Benchpress ()
* Use Benchpress

* Use Benchpress.compileParse

* Error for template load failure

* Use benchpressjs package

* Compile templates on demand

* Fix user settings page

* Fix admin search to exclude `.jst` files

* Fix 500-embed

So ajaxify can still show an error if the server goes down
Barış Soner Uşaklı 75e5073fc9 closes
Barış Soner Uşaklı 5d53c41db7 fix unlink calls
Peter Jaszkowiak c4bdb72941 ESlint no-unneeded-ternary
and no-extend-native, no-sequences
Peter Jaszkowiak feb8405f95 ESlint eol-last
Peter Jaszkowiak a038c66549 ESlint quotes
Peter Jaszkowiak 604358ecc4 ESlint keyword-spacing, no-multi-spaces
Peter Jaszkowiak 2e031f3759 ESlint comma-spacing
Peter Jaszkowiak 277a7fb8b4 ESlint key-spacing, no-trailing-spaces