Commit Graph

8648 Commits

Author SHA1 Message Date
IanM
03d2d7eabb
feat: expose {time} to eventPost data, fix renamed tooltip (#3698) 2023-01-17 20:47:02 +01:00
ornanovitch
4d292263b5
fix(tags): tag text color contrast (#3653)
* add yiq calculator util
* use the new contast util to differentiate light/dark tags
* fix: invert logic
* feat: add tag-dark and tag-light less config
* fix: convert 3 chars hex to 6 chars hex
* fix: rename import
* fix: clarify util name
* fix: rename function
* fix: invert less variables when dark mode is enabled
* fix: TagTiles contrast
* refactor: simplify logic with a unique variable
* refactor: simplify logic with a unique variable
* feat: add text color variables not depending on the dark/light mode
* refactor: use isDark rather than getContrast
* refactor: change getContrast to isDark with for a more direct approach
* fix: adjust snippet description
* refactor: change getContrast to isDark with for a more direct approach
* fix: adjust snippet description
* fix: TagHero contrast
* fix: DiscussionHero contrast
* fix: newDiscussion contrast
* fix(newDiscussion): restore less rule when tag is not colored
* fix: TagTiles description
* fix: TagTiles last posted
* chore: change `var` to `let`
* refactor: keep it for backwards compatibility
* refactor: keep it for backwards compatibility
* Apply suggestions from code review
* fix: missed this when I was resolving
* fix: remove dist files from pull request
* Revert "Resolved merge conflict"
This reverts commit c7f0d14aa8, reversing
changes made to 6753dfc2af.
* fix: missed this when I was resolving
* fix
* Update isDark.ts
* chore: flexible contrast color fixing
* refactor(isDark): clarify the doc block
* fix(isDark): increase the yiq threshold
* typo
* fix: preserve design coloring through light and dark modes

Co-authored-by: David Wheatley <david@davwheat.dev>
Co-authored-by: Sami Mazouz <sychocouldy@gmail.com>
2023-01-17 20:45:03 +01:00
flarum-bot
6adae00f72 Bundled output for commit d7f4975330
Includes transpiled JS/TS, and Typescript declaration files (typings).

[skip ci]
2023-01-17 18:15:45 +00:00
Sami Mazouz
d7f4975330
feat: introduce frontend extenders (#3645)
* feat: reintroduce frontend extenders
* chore: used `Routes` extender in bundled extensions
* chore: used `PostTypes` extender in bundled extensions
* chore: `yarn format`
* chore: naming
* chore(review): unnecessary check
* chore(review): stay consistent
* chore: unused import

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
2023-01-17 19:10:24 +01:00
Sami Mazouz
5fe3cfd837
feat(phpstan): foundation for usage in extensions (#3666)
* feat(phpstan): pick up extended model relations typings
* feat(phpstan): pick up extended model date attributes
* feat(core): introduce `castAttribute` extender
Stops using `dates` as it's deprecated in laravel 8
* feat(phpstan): pick up extended model attributes through casts
* fix: extenders not resolved when declared namespace
* fix(phpstan): new model attributes are always nullable
* chore(phpstan): add helpful cache clearing command
* Apply fixes from StyleCI
* chore: improve extend files provider logic
* chore: rename `castAttribute` to just `cast`
* chore: update phpstan package to detect `cast` method
* Update framework/core/src/Extend/Model.php

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
2023-01-15 15:25:13 +01:00
Sami Mazouz
2d2bf5c504
fix: permissions table on mobile is unusable (#3722) 2023-01-14 19:34:12 +01:00
Sami Mazouz
a4f4ee8e71
chore: Merge 1.6.3 into main 2023-01-13 19:57:31 +01:00
Sami Mazouz
4a38047bfb
Merge branch 'main' into merge-1.6.3-into-main 2023-01-13 19:12:11 +01:00
flarum-bot
d5e6f6db5f Bundled output for commit 20e7d245da
Includes transpiled JS/TS, and Typescript declaration files (typings).

[skip ci]
2023-01-13 08:37:32 +00:00
Tristian Kelly
20e7d245da
feat: Admin User Search (#3712)
* Initial search
* oninput attempt
* Working search!
* forgot to format
* fix debounce, locale
* use core.ref
2023-01-13 09:31:22 +01:00
Sami Mazouz
243bc139b0
chore: changelog
Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
2023-01-10 15:22:17 +01:00
Sami Mazouz
adf78bbd95
chore(subscriptions): prepare
Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
2023-01-10 15:06:03 +01:00
StyleCI Bot
c8d9f1111e
Apply fixes from StyleCI 2023-01-10 14:04:18 +00:00
Sami Mazouz
e5f05166a0
fix(subscriptions): post notifications not getting access checked
Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
2023-01-10 15:04:02 +01:00
Sami Mazouz
02556c6ca6
chore: prepare v1.6.3 release
Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
2023-01-10 15:00:38 +01:00
Sami Mazouz
666223fa8c
test: make data providers public
Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
2023-01-10 15:00:38 +01:00
Sami Mazouz
12dfcc5c79
Merge pull request from GHSA-hph3-hv3c-7725
* test: add reply creation tests

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>

* fix: access checking being bypassed for post creation when first post is deleted

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>

* chore: recover tests

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>

* chore: make provider public

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
2023-01-10 15:00:38 +01:00
StyleCI Bot
248a71d9b5
Apply fixes from StyleCI 2023-01-10 15:00:37 +01:00
Sami Mazouz
a131e87911
Merge pull request from GHSA-8gcg-vwmw-rxj4
* fix: notifications grant access to private data of posts

* chore: fix tests

* test: start with tests about notification subject visibility

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>

* fix: check subject access before sending notification to user

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
Co-authored-by: Daniël Klabbers <daniel@klabbers.email>
2023-01-10 15:00:37 +01:00
StyleCI Bot
be63b28437
Apply fixes from StyleCI 2023-01-10 15:00:37 +01:00
Sami Mazouz
132fdea659
Merge pull request from GHSA-22m9-m3ww-53h3
* fix: check post visibility when mentioning

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>

* fix: `mentionsPosts` include is not used and leaks private posts

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>

* chre: use `PostRepository`

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
2023-01-10 15:00:37 +01:00
dependabot[bot]
fe8480c8f7
chore(deps): bump json5 from 2.2.1 to 2.2.3 (#3717)
Bumps [json5](https://github.com/json5/json5) from 2.2.1 to 2.2.3.
- [Release notes](https://github.com/json5/json5/releases)
- [Changelog](https://github.com/json5/json5/blob/main/CHANGELOG.md)
- [Commits](https://github.com/json5/json5/compare/v2.2.1...v2.2.3)

---
updated-dependencies:
- dependency-name: json5
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-01-09 16:54:29 +01:00
IanM
1e8a0f930d
fix: load actor.groups (#3716) 2023-01-09 12:00:46 +01:00
Daniël Klabbers
d7b9a03f31 chore: fix php 8.1 on preg_match 2nd argument being null, which also optimizes slightly 2022-12-17 01:05:38 +01:00
flarum-bot
78189f29d2 Bundled output for commit 07f8b6161a
Includes transpiled JS/TS, and Typescript declaration files (typings).

[skip ci]
2022-12-12 10:18:58 +00:00
IanM
07f8b6161a
fix: support 3digit hex color input (#3706) 2022-12-12 10:14:59 +00:00
flarum-bot
0eff1f6b2d Bundled output for commit a53a0db2b7
Includes transpiled JS/TS, and Typescript declaration files (typings).

[skip ci]
2022-12-12 09:48:42 +00:00
Sami Mazouz
a53a0db2b7
feat(tags): admin tag selection component (reusable tag selection modal) (#3686)
* chore: move `KeyboardNavigation` to `common` first
* feat: exract reusable `TagSelectionModal` from `TagDiscussionModal`
* fix: improve for generic use
* feat: add select tags admin setting component
2022-12-12 10:44:33 +01:00
flarum-bot
a129999132 Bundled output for commit 8f80cde5b7
Includes transpiled JS/TS, and Typescript declaration files (typings).

[skip ci]
2022-12-03 21:19:51 +00:00
Sami Mazouz
8f80cde5b7
feat: allow using utf8 characters in tag slugs (#3588)
* feat: allow using utf8 characters in slugs
url-encoded slugs are not read by the backend.
* chore: use as a slug driver
* chore: refactor tests to use data provider
* Apply fixes from StyleCI
* fix: wrong resource used
* fix: forgotten slug from slug manager in serializer
* chore(review): adapt tag slug suggestions on the UI
* chore: introduce modes for slugging
* chore: `yarn format`

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
2022-12-03 22:15:34 +01:00
flarum-bot
4de3cd4d9c Bundled output for commit 3dd2cadb9b
Includes transpiled JS/TS, and Typescript declaration files (typings).

[skip ci]
2022-11-30 16:46:54 +00:00
IanM
3dd2cadb9b
fix: undefined showing in dropdown active title (#3700) 2022-11-30 16:39:32 +00:00
Rafael Horvat
605225c851
fix: column id can be ambiguous in group filter with extensions (#3696) 2022-11-27 10:44:06 +01:00
flarum-bot
f33fbdd0b5 Bundled output for commit 5bc47c0278
Includes transpiled JS/TS, and Typescript declaration files (typings).

[skip ci]
2022-11-27 09:40:52 +00:00
Sami Mazouz
5bc47c0278
chore: convert Dropdown components to TS (#3608)
* chore: convert `Dropdown` components to TS
* chore(review): `buttonClassName` technically not required
* chore(review): `accessibleToggleLabel` technically not required
* chore(review): use `classList` where possible
* chore: `yarn format`
* Update framework/core/js/src/common/components/Dropdown.tsx
* chore(review): use `includes`
* chore(review): define constant of excluded groups
* chore(review): use `null coalesce` and `logical or` assignments
* chore(review): `null coalesce`
* chore(review): `any` to `typeof Component`
* chore(review): `classList`
* chore(review): `yarn format`
* chore: fix typing issues after typescript update

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
Co-authored-by: David Wheatley <hi@davwheat.dev>
2022-11-27 10:34:29 +01:00
flarum-bot
0e238a9c82 Bundled output for commit 64fa35f2f3
Includes transpiled JS/TS, and Typescript declaration files (typings).

[skip ci]
2022-11-25 17:25:24 +00:00
Sami Mazouz
64fa35f2f3
chore: update JS dependencies (#3695)
* chore: lock mithril to `2.0` because `2.2` has breaking changes with no upgrade guide
* chore: update JS dependencies `yarn upgrade`
* chore: fix typings after js deps updates
* chore(review): better semver

Co-authored-by: David Wheatley <hi@davwheat.dev>
2022-11-25 18:20:30 +01:00
flarum-bot
c99d04fce2 Bundled output for commit 67c0d75ebc
Includes transpiled JS/TS, and Typescript declaration files (typings).

[skip ci]
2022-11-25 11:11:04 +00:00
IanM
67c0d75ebc
feat: include current user as forum relation (#3668)
* feat: include current user as forum relation

* Update framework/core/src/Api/Controller/ShowForumController.php

Co-authored-by: Sami Mazouz <sychocouldy@gmail.com>

* Update framework/core/src/Api/Controller/ShowForumController.php

Co-authored-by: Sami Mazouz <sychocouldy@gmail.com>

* Update framework/core/src/Api/Serializer/ForumSerializer.php

Co-authored-by: Sami Mazouz <sychocouldy@gmail.com>

* Update framework/core/tests/integration/api/forum/ShowTest.php

Co-authored-by: Sami Mazouz <sychocouldy@gmail.com>

* Update framework/core/tests/integration/api/forum/ShowTest.php

Co-authored-by: Sami Mazouz <sychocouldy@gmail.com>

* No need to call the user endpoint as we already have the data loaded

* chore: return types

Co-authored-by: Sami Mazouz <sychocouldy@gmail.com>
2022-11-25 11:00:19 +00:00
IanM
6f4f964ce8
feat: allow push additional items to the end of the poststream (#3691)
* feat: allow push additional items to the end of the poststream

* Update framework/core/js/src/forum/components/PostStream.js

Co-authored-by: David Wheatley <hi@davwheat.dev>

* chore: prettier

* Update framework/core/js/src/forum/components/PostStream.js

Co-authored-by: David Wheatley <hi@davwheat.dev>

Co-authored-by: David Wheatley <hi@davwheat.dev>
2022-11-25 10:59:23 +00:00
Ian Morland
67dd2c21b6
fix: provide web friendly session driver name (#3690) 2022-11-22 17:02:44 +00:00
flarum-bot
e5d2b8cad9 Bundled output for commit f5c346f1c7
Includes transpiled JS/TS, and Typescript declaration files (typings).

[skip ci]
2022-11-20 12:08:32 +00:00
Clark Winkelmann
f5c346f1c7
chore: Indicate cross-origin request in generic error message (#3669)
* Indicate cross-origin request in generic error message
* Run javascript format
* Move text to beginning of error message
* Update framework/core/locale/core.yml

Co-authored-by: David Wheatley <hi@davwheat.dev>
2022-11-20 13:02:41 +01:00
flarum-bot
5bb0593bad Bundled output for commit 47d2053766
Includes transpiled JS/TS, and Typescript declaration files (typings).

[skip ci]
2022-11-19 22:30:32 +00:00
Ian Morland
47d2053766
feat: expose queue driver, schedule status (#3593)
* feat: expose queue driver, schedule status

* Apply fixes from StyleCI

* docblock

* fix inheritdoc

* Add info link for scheduler setup

* Remove unsed import

* fix: phpstan error

* Only show scheduler status when jobs are registered

* Apply fixes from StyleCI

* add ItemList priorities

* Add translations

* Include schedule status in info console cmd

* Apply fixes from StyleCI

* Move identifyX logic into shared 'ApplicationInfoProvider'

* Apply fixes from StyleCI

* uniform data layout

* inject queue

Co-authored-by: StyleCI Bot <bot@styleci.io>
2022-11-19 22:23:04 +00:00
Sami Mazouz
e0b9dcfbcd
Merge branch 'release/v1.6.2'
# Conflicts:
#	framework/core/js/dist/admin.js
#	framework/core/js/dist/admin.js.map
#	framework/core/js/dist/forum.js
#	framework/core/js/dist/forum.js.map
#	framework/core/src/Foundation/Application.php
2022-11-18 23:24:43 +01:00
Sami Mazouz
8a65ad980d
chore: v1.6.2 changelog
Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
2022-11-18 22:38:41 +01:00
Sami Mazouz
9a0668effd
chore: update version constant to v1.6.2
Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
2022-11-18 22:35:12 +01:00
Sami Mazouz
224b122303
chore: yarn build
Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
2022-11-18 22:34:29 +01:00
Sami Mazouz
ed0cee97f5
fix: evaluated page title content (#3684)
* fix: evaluated page title content
* chore: add comment
* chore: use DOMParser instead
* fix: use `innerHTML` for the actual value

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
Co-authored-by: David Wheatley <hi@davwheat.dev>
2022-11-18 22:32:24 +01:00