mirror of
https://github.com/flarum/core.git
synced 2025-08-17 22:01:44 +02:00
Compare commits
11 Commits
dk/DISCUSS
...
v1.8.0
Author | SHA1 | Date | |
---|---|---|---|
|
d27f952584 | ||
|
e5abffc75b | ||
|
d1059c1cc7 | ||
|
777c304ab7 | ||
|
789246b621 | ||
|
980cfd6c28 | ||
|
65390a4fc0 | ||
|
c7c86a77e9 | ||
|
f1f6051deb | ||
|
bded3da42d | ||
|
231cee1f78 |
8
.github/workflows/prepare-release.yml
vendored
8
.github/workflows/prepare-release.yml
vendored
@@ -20,7 +20,7 @@ jobs:
|
|||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
- name: Prepare release
|
- name: Prepare release
|
||||||
uses: flarum/action-release@master
|
uses: flarum/action-release@master
|
||||||
env:
|
with:
|
||||||
NEXT_TAG: ${{ inputs.version }}
|
next_tag: ${{ inputs.version }}
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
OPEN_COLLECTIVE_TOKEN: ${{ secrets.OPEN_COLLECTIVE_TOKEN }}
|
open_collective_token: ${{ secrets.OPEN_COLLECTIVE_TOKEN }}
|
||||||
|
44
CHANGELOG.md
44
CHANGELOG.md
@@ -1,5 +1,49 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## [v1.8.0](https://github.com/flarum/framework/compare/v1.7.1...v1.8.0)
|
||||||
|
### Fixed
|
||||||
|
- (a11y) reply placeholder not accessible [#3793]
|
||||||
|
- (bbcode) highlight.js does not work after changing post content [#3817]
|
||||||
|
- (bbcode) localize quote `wrote` string [#3809]
|
||||||
|
- (mentions) mentions XHR fired even after mentioning is done [#3806]
|
||||||
|
- (package-manager) available core updates cause an error in the dashboard ([fab71f2](fab71f2d01fa20ce9b3002833339dc5ea3ea6301))
|
||||||
|
- (tags) not all tags are loaded in the permission grid [#3804]
|
||||||
|
- (tags) tag discussion modal filters with exact matches only after first index [#3786]
|
||||||
|
- (testing) always clear cache in integration test's tearDown [#3818]
|
||||||
|
- `UserSecurityPage` not exported ([232618a](232618aba604ab003425df38b895208c863d3260))
|
||||||
|
- `isDark()` utility can receive null value [#3774]
|
||||||
|
- approving a post does not bump user `comment_count` [#3790]
|
||||||
|
- circular dependencies disable all involved extensions [#3785]
|
||||||
|
- color input overflowing the input box [#3796]
|
||||||
|
- deleting a discussion from the profile does not visually remove it [#3799]
|
||||||
|
- discussion page showing horizontal scroll on iOS [#3821]
|
||||||
|
- empty string displayed as SelectDropdown title [#3773]
|
||||||
|
- filter values are not validated [#3795]
|
||||||
|
- infinite scroll not initialized for notifications on big screens [#3733]
|
||||||
|
- notification subject discussion eager loading fails [#3788]
|
||||||
|
- null as 2nd param in `preg_match` is deprecated [#3801]
|
||||||
|
- unread count in post stream not visible [#3791]
|
||||||
|
- unreadable badge icon on certain colors [#3810]
|
||||||
|
- integrity constraint violation [#3772]
|
||||||
|
### Changed
|
||||||
|
- (core,mentions) limit `mentionedBy` post relation results [#3780]
|
||||||
|
- (likes) limit `likes` relationship results [#3781]
|
||||||
|
- Change some methods from private to protected, to be able to extend the affected classes [#3802]
|
||||||
|
- Do not catch exceptions when testing Console commands [#3813]
|
||||||
|
- drop usage of jquery in `install` and `update` interfaces [#3797]
|
||||||
|
- extensibility improvements [#3729]
|
||||||
|
- major frontend JS cleanup [#3609]
|
||||||
|
- revert ineffective code for encoding of page title [#3768]
|
||||||
|
- speed up post creation time [#3808]
|
||||||
|
### Added
|
||||||
|
- (mentions,tags) tag mentions [#3769]
|
||||||
|
- add delete own posts permission [#3784]
|
||||||
|
- add a trait to flush the formatter cache in tests [#3811]
|
||||||
|
- add user creation to users list page [#3744]
|
||||||
|
- cli command for enabling or disabling an extension [#3816]
|
||||||
|
- conditional extenders [#3759]
|
||||||
|
- provide old content to `Revised` event [#3789]
|
||||||
|
|
||||||
## [v1.7.1](https://github.com/flarum/framework/compare/v1.7.0...v1.7.1)
|
## [v1.7.1](https://github.com/flarum/framework/compare/v1.7.0...v1.7.1)
|
||||||
### Fixed
|
### Fixed
|
||||||
- (tags) composer tag selection modal using wrong primary max & min numbers (abc9670659426b765274376945b818b70d84848c)
|
- (tags) composer tag selection modal using wrong primary max & min numbers (abc9670659426b765274376945b818b70d84848c)
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7",
|
"flarum/core": "^1.8",
|
||||||
"flarum/approval": "^1.7"
|
"flarum/approval": "^1.7"
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7",
|
"flarum/core": "^1.8",
|
||||||
"flarum/flags": "^1.7"
|
"flarum/flags": "^1.7"
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7"
|
"flarum/core": "^1.8"
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"psr-4": {
|
"psr-4": {
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7"
|
"flarum/core": "^1.8"
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"psr-4": {
|
"psr-4": {
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7"
|
"flarum/core": "^1.8"
|
||||||
},
|
},
|
||||||
"extra": {
|
"extra": {
|
||||||
"branch-alias": {
|
"branch-alias": {
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7"
|
"flarum/core": "^1.8"
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"psr-4": {
|
"psr-4": {
|
||||||
|
@@ -7,7 +7,7 @@
|
|||||||
],
|
],
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7"
|
"flarum/core": "^1.8"
|
||||||
},
|
},
|
||||||
"extra": {
|
"extra": {
|
||||||
"branch-alias": {
|
"branch-alias": {
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7"
|
"flarum/core": "^1.8"
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"psr-4": {
|
"psr-4": {
|
||||||
|
@@ -44,7 +44,6 @@ class LoadLikesRelationship
|
|||||||
$loadable = null;
|
$loadable = null;
|
||||||
|
|
||||||
if ($data instanceof Discussion) {
|
if ($data instanceof Discussion) {
|
||||||
// @phpstan-ignore-next-line
|
|
||||||
$loadable = $data->newCollection($data->posts)->filter(function ($post) {
|
$loadable = $data->newCollection($data->posts)->filter(function ($post) {
|
||||||
return $post instanceof Post;
|
return $post instanceof Post;
|
||||||
});
|
});
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7"
|
"flarum/core": "^1.8"
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"psr-4": {
|
"psr-4": {
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7"
|
"flarum/core": "^1.8"
|
||||||
},
|
},
|
||||||
"extra": {
|
"extra": {
|
||||||
"branch-alias": {
|
"branch-alias": {
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7"
|
"flarum/core": "^1.8"
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"psr-4": {
|
"psr-4": {
|
||||||
|
@@ -47,8 +47,7 @@ class LoadMentionedByRelationship
|
|||||||
$loadable = null;
|
$loadable = null;
|
||||||
|
|
||||||
if ($data instanceof Discussion) {
|
if ($data instanceof Discussion) {
|
||||||
// @phpstan-ignore-next-line
|
$loadable = $data->newCollection($data->posts)->filter(function ($post) {
|
||||||
$loadable = $data->newCollection((array) $data->posts)->filter(function ($post) {
|
|
||||||
return $post instanceof Post;
|
return $post instanceof Post;
|
||||||
});
|
});
|
||||||
} elseif ($data instanceof Collection) {
|
} elseif ($data instanceof Collection) {
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7"
|
"flarum/core": "^1.8"
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"psr-4": {
|
"psr-4": {
|
||||||
|
@@ -22,7 +22,7 @@
|
|||||||
"source": "https://github.com/flarum/package-manager"
|
"source": "https://github.com/flarum/package-manager"
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.5.0",
|
"flarum/core": "^1.8",
|
||||||
"composer/composer": "^2.3"
|
"composer/composer": "^2.3"
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7",
|
"flarum/core": "^1.8",
|
||||||
"pusher/pusher-php-server": "^2.2"
|
"pusher/pusher-php-server": "^2.2"
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7"
|
"flarum/core": "^1.8"
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"psr-4": {
|
"psr-4": {
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7"
|
"flarum/core": "^1.8"
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"psr-4": {
|
"psr-4": {
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7"
|
"flarum/core": "^1.8"
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"psr-4": {
|
"psr-4": {
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7"
|
"flarum/core": "^1.8"
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"psr-4": {
|
"psr-4": {
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"flarum/core": "^1.7"
|
"flarum/core": "^1.8"
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"psr-4": {
|
"psr-4": {
|
||||||
|
@@ -19,6 +19,10 @@
|
|||||||
&.colored &-text, &--colored &-text {
|
&.colored &-text, &--colored &-text {
|
||||||
color: var(--tag-color) !important;
|
color: var(--tag-color) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&-icon {
|
||||||
|
margin-right: 2px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.TagLabel {
|
.TagLabel {
|
||||||
|
@@ -26,7 +26,7 @@ class TagRepository
|
|||||||
return Tag::query();
|
return Tag::query();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function queryVisibleTo(User $actor): Builder
|
public function queryVisibleTo(?User $actor = null): Builder
|
||||||
{
|
{
|
||||||
return $this->scopeVisibleTo($this->query(), $actor);
|
return $this->scopeVisibleTo($this->query(), $actor);
|
||||||
}
|
}
|
||||||
@@ -114,7 +114,7 @@ class TagRepository
|
|||||||
* @param User|null $user
|
* @param User|null $user
|
||||||
* @return Builder<Tag>
|
* @return Builder<Tag>
|
||||||
*/
|
*/
|
||||||
protected function scopeVisibleTo(Builder $query, User $user = null)
|
protected function scopeVisibleTo(Builder $query, ?User $user = null)
|
||||||
{
|
{
|
||||||
if ($user !== null) {
|
if ($user !== null) {
|
||||||
$query->whereVisibleTo($user);
|
$query->whereVisibleTo($user);
|
||||||
|
2
framework/core/js/dist-typings/forum/components/AvatarEditor.d.ts
generated
vendored
2
framework/core/js/dist-typings/forum/components/AvatarEditor.d.ts
generated
vendored
@@ -72,7 +72,7 @@ export default class AvatarEditor extends Component<import("../../common/Compone
|
|||||||
remove(): void;
|
remove(): void;
|
||||||
/**
|
/**
|
||||||
* After a successful upload/removal, push the updated user data into the
|
* After a successful upload/removal, push the updated user data into the
|
||||||
* store, and force a recomputation of the user's avatar color.
|
* store, and force a re-computation of the user's avatar color.
|
||||||
*
|
*
|
||||||
* @param {object} response
|
* @param {object} response
|
||||||
* @protected
|
* @protected
|
||||||
|
2
framework/core/js/dist/forum.js
generated
vendored
2
framework/core/js/dist/forum.js
generated
vendored
File diff suppressed because one or more lines are too long
2
framework/core/js/dist/forum.js.map
generated
vendored
2
framework/core/js/dist/forum.js.map
generated
vendored
File diff suppressed because one or more lines are too long
@@ -204,7 +204,7 @@ export default class AvatarEditor extends Component {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* After a successful upload/removal, push the updated user data into the
|
* After a successful upload/removal, push the updated user data into the
|
||||||
* store, and force a recomputation of the user's avatar color.
|
* store, and force a re-computation of the user's avatar color.
|
||||||
*
|
*
|
||||||
* @param {object} response
|
* @param {object} response
|
||||||
* @protected
|
* @protected
|
||||||
|
@@ -98,7 +98,7 @@ export default class DiscussionListItem<CustomAttrs extends IDiscussionListItemA
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<span
|
<span
|
||||||
className={classList('Slidable-underneath Slidable-underneath--left Slidable-underneath--elastic', { disabled: isUnread })}
|
className={classList('Slidable-underneath Slidable-underneath--left Slidable-underneath--elastic', { disabled: !isUnread })}
|
||||||
onclick={this.markAsRead.bind(this)}
|
onclick={this.markAsRead.bind(this)}
|
||||||
>
|
>
|
||||||
{icon('fas fa-check')}
|
{icon('fas fa-check')}
|
||||||
|
@@ -62,7 +62,7 @@ class UploadFaviconController extends UploadImageController
|
|||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
$encodedImage = $this->imageManager->make($file->getStream())->resize(64, 64, function ($constraint) {
|
$encodedImage = $this->imageManager->make($file->getStream()->getMetadata('uri'))->resize(64, 64, function ($constraint) {
|
||||||
$constraint->aspectRatio();
|
$constraint->aspectRatio();
|
||||||
$constraint->upsize();
|
$constraint->upsize();
|
||||||
})->encode('png');
|
})->encode('png');
|
||||||
|
@@ -38,7 +38,7 @@ class UploadLogoController extends UploadImageController
|
|||||||
*/
|
*/
|
||||||
protected function makeImage(UploadedFileInterface $file): Image
|
protected function makeImage(UploadedFileInterface $file): Image
|
||||||
{
|
{
|
||||||
$encodedImage = $this->imageManager->make($file->getStream())->heighten(60, function ($constraint) {
|
$encodedImage = $this->imageManager->make($file->getStream()->getMetadata('uri'))->heighten(60, function ($constraint) {
|
||||||
$constraint->upsize();
|
$constraint->upsize();
|
||||||
})->encode('png');
|
})->encode('png');
|
||||||
|
|
||||||
|
@@ -256,7 +256,10 @@ abstract class AbstractModel extends Eloquent
|
|||||||
return $result;
|
return $result;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function newCollection(array $models = [])
|
/**
|
||||||
|
* @param \Illuminate\Support\Collection|array $models
|
||||||
|
*/
|
||||||
|
public function newCollection($models = [])
|
||||||
{
|
{
|
||||||
return new Collection($models);
|
return new Collection($models);
|
||||||
}
|
}
|
||||||
|
@@ -21,7 +21,7 @@ class Application
|
|||||||
*
|
*
|
||||||
* @var string
|
* @var string
|
||||||
*/
|
*/
|
||||||
const VERSION = '1.8.0-dev';
|
const VERSION = '1.8.0';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The IoC container for the Flarum application.
|
* The IoC container for the Flarum application.
|
||||||
|
@@ -41,7 +41,7 @@ class GroupRepository
|
|||||||
return $this->scopeVisibleTo($query, $actor)->firstOrFail();
|
return $this->scopeVisibleTo($query, $actor)->firstOrFail();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function queryVisibleTo(User $actor = null)
|
public function queryVisibleTo(?User $actor = null)
|
||||||
{
|
{
|
||||||
return $this->scopeVisibleTo($this->query(), $actor);
|
return $this->scopeVisibleTo($this->query(), $actor);
|
||||||
}
|
}
|
||||||
@@ -53,7 +53,7 @@ class GroupRepository
|
|||||||
* @param User|null $actor
|
* @param User|null $actor
|
||||||
* @return Builder<Group>
|
* @return Builder<Group>
|
||||||
*/
|
*/
|
||||||
protected function scopeVisibleTo(Builder $query, User $actor = null)
|
protected function scopeVisibleTo(Builder $query, ?User $actor = null)
|
||||||
{
|
{
|
||||||
if ($actor !== null) {
|
if ($actor !== null) {
|
||||||
$query->whereVisibleTo($actor);
|
$query->whereVisibleTo($actor);
|
||||||
|
@@ -29,7 +29,7 @@ class PostRepository
|
|||||||
* @param User|null $user
|
* @param User|null $user
|
||||||
* @return Builder<Post>
|
* @return Builder<Post>
|
||||||
*/
|
*/
|
||||||
public function queryVisibleTo(User $user = null)
|
public function queryVisibleTo(?User $user = null)
|
||||||
{
|
{
|
||||||
$query = $this->query();
|
$query = $this->query();
|
||||||
|
|
||||||
|
@@ -87,7 +87,7 @@ class AvatarValidator extends AbstractValidator
|
|||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
$this->imageManager->make($file->getStream());
|
$this->imageManager->make($file->getStream()->getMetadata('uri'));
|
||||||
} catch (NotReadableException $_e) {
|
} catch (NotReadableException $_e) {
|
||||||
$this->raise('image');
|
$this->raise('image');
|
||||||
}
|
}
|
||||||
|
@@ -74,7 +74,7 @@ class UploadAvatarHandler
|
|||||||
|
|
||||||
$this->validator->assertValid(['avatar' => $command->file]);
|
$this->validator->assertValid(['avatar' => $command->file]);
|
||||||
|
|
||||||
$image = $this->imageManager->make($command->file->getStream());
|
$image = $this->imageManager->make($command->file->getStream()->getMetadata('uri'));
|
||||||
|
|
||||||
$this->events->dispatch(
|
$this->events->dispatch(
|
||||||
new AvatarSaving($user, $actor, $image)
|
new AvatarSaving($user, $actor, $image)
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "flarum-webpack-config",
|
"name": "flarum-webpack-config",
|
||||||
"version": "2.0.1",
|
"version": "2.0.2",
|
||||||
"description": "Webpack config for Flarum JS and TS transpilation.",
|
"description": "Webpack config for Flarum JS and TS transpilation.",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"author": "Flarum Team",
|
"author": "Flarum Team",
|
||||||
|
Reference in New Issue
Block a user