1
0
mirror of https://github.com/flarum/core.git synced 2025-08-26 01:34:16 +02:00
Commit Graph

8263 Commits

Author SHA1 Message Date
flarum-bot
3f5f3320a9 Bundled output for commit 80e32594e2 [skip ci] 2020-04-24 20:30:18 +00:00
Alexander Skvortsov
80e32594e2 Disable "Start Discussion" button for restricted tags (#74)
Also, change the label when the button is disabled.
2020-04-24 22:29:16 +02:00
Franz Liedke
be67f73760 Tweak spoiler code
Refs #13, #14, flarum/core#2053.
2020-04-24 22:10:36 +02:00
Alexander Skvortsov
6416fbd5d3 Model extender: Fix inheritance (#2132)
This ensures that default values, date attributes and relationships are properly inherited, when we have deeper model class hierarchies.

This also adds test cases to ensure that inheritance order is honored for relationship and default attribute extender. As there's no way to remove date attributes, the order of evaluation there doesn't matter.
2020-04-24 21:17:31 +02:00
Matt Kilgore
ebd30401a8 fix: Removed mentions specific spoiler code (#14)
Also fixed links, code and images in spoiler, and hopefully all other children.

The block spoiler works fine without fixes, global spoiler class causes issues.
2020-04-24 17:58:38 +02:00
Franz Liedke
74027a8421 Model extender: Add failing test
We determined that child classes are not properly affected when
extending the parent classes.

Refs #2100.
2020-04-24 17:54:30 +02:00
Franz Liedke
4ac4af54e6 Fix test to match its description
Refs #2100.
2020-04-24 17:31:08 +02:00
Franz Liedke
56ef8b4613 Apply fixes from StyleCI
[ci skip] [skip ci]
2020-04-24 14:56:37 +00:00
Franz Liedke
c87c2bcd4c Tweak model extender tests
- Format code
- Reorder methods
- Test a different scenario to avoid the use of sleep()

Refs #2100.
2020-04-24 16:55:04 +02:00
Franz Liedke
4e95b2b719 Clean up model extender
- Remove unused private attributes
- Complete docblocks
- Add scalar type hints
- Format code
- Reorder methods

Refs #2100.
2020-04-24 16:33:08 +02:00
Franz Liedke
649f71d25a Use new Model extender 2020-04-24 15:56:27 +02:00
Franz Liedke
91d7b6730f Use new Model extender 2020-04-24 15:56:07 +02:00
Franz Liedke
a552b957ba Use new Model extender 2020-04-24 15:55:50 +02:00
Franz Liedke
8c90c1d2da Use new Model extender 2020-04-24 15:55:35 +02:00
Franz Liedke
cf764d2c00 Use new Model extender 2020-04-24 15:55:19 +02:00
Franz Liedke
6fa5cc4408 Use new Model extender 2020-04-24 15:54:12 +02:00
Franz Liedke
6dc362f760 Apply fixes from StyleCI
[ci skip] [skip ci]
2020-04-24 13:10:36 +00:00
Alexander Skvortsov
ef44ff5603 Add model extender (#2100)
This covers default attribute values, date attributes and custom relationships.
2020-04-24 15:10:24 +02:00
Franz Liedke
dfbff262f2 npm audit fix 2020-04-24 14:33:48 +02:00
flarum-bot
f022018be3 Bundled output for commit 751c14c889 [skip ci] 2020-04-24 12:33:10 +00:00
flarum-bot
25ba9b70a5 Bundled output for commit 8b2c90c142 [skip ci] 2020-04-24 12:32:41 +00:00
flarum-bot
86577e26d2 Bundled output for commit cb3f14b186 [skip ci] 2020-04-24 12:32:32 +00:00
flarum-bot
a5f87d4e2e Bundled output for commit 5beb553730 [skip ci] 2020-04-24 12:31:59 +00:00
Franz Liedke
cadb279bf1 npm audit fix 2020-04-24 14:30:31 +02:00
Franz Liedke
2d9c38674b npm audit fix 2020-04-24 14:30:31 +02:00
Franz Liedke
751c14c889 npm audit fix 2020-04-24 14:30:31 +02:00
Franz Liedke
fbd50d390a npm audit fix 2020-04-24 14:30:30 +02:00
Franz Liedke
8b2c90c142 npm audit fix 2020-04-24 14:30:30 +02:00
Franz Liedke
912254864c npm audit fix 2020-04-24 14:30:29 +02:00
Franz Liedke
9587d3b416 npm audit fix 2020-04-24 14:30:29 +02:00
Franz Liedke
cb3f14b186 npm audit fix 2020-04-24 14:30:29 +02:00
Franz Liedke
d01f3cde0e npm audit fix 2020-04-24 14:30:28 +02:00
Franz Liedke
e308a7ae60 npm audit fix 2020-04-24 14:30:28 +02:00
Franz Liedke
474b1296b6 npm audit fix 2020-04-24 14:30:27 +02:00
Franz Liedke
92b18063f5 npm audit fix 2020-04-24 14:30:27 +02:00
Franz Liedke
5beb553730 npm audit fix 2020-04-24 14:30:27 +02:00
Franz Liedke
e3740876b7 npm audit fix 2020-04-24 14:30:25 +02:00
Franz Liedke
519fc3d970 npm audit fix 2020-04-24 14:30:25 +02:00
Franz Liedke
173a698fb4 npm audit fix 2020-04-24 14:30:16 +02:00
flarum-bot
e2db63253f Bundled output for commit d30b2dee3e [skip ci] 2020-04-22 21:38:57 +00:00
Franz Liedke
d30b2dee3e CI: Shorten the lint job name 2020-04-22 23:37:37 +02:00
Franz Liedke
82c67588e4 Add translations for hidden permission groups
Refs flarum/core#2129, flarum/core#845, closes #153.
2020-04-21 21:05:49 +02:00
Alexander Skvortsov
7dd5c92c31 Implement hidden permission groups (#2129)
Only users that have the new `viewHiddenGroups` permissions will be able to see these groups.

You might want this when you want to give certain users special permissions, but don't want to make your authorization scheme public to regular users.

Co-authored-by: luceos <daniel+github@klabbers.email>
2020-04-21 17:49:53 +02:00
Franz Liedke
b479a22186 Statically access Flarum version everywhere
One less reason to inject the huge Application class.

Refs #2055.
2020-04-21 16:48:36 +02:00
Franz Liedke
af932c3c20 Use Container contract where easily possible
Less usages of the Application god-class simplifies splitting it up.

Refs #2055.
2020-04-21 16:48:06 +02:00
Franz Liedke
afc0fae966 Add compatiblity with Composer 2.0
- The structure of vendor/composer/installed.json will change.
- The same file will now contain the relative path to package locations.

References:
- https://github.com/composer/composer/blob/master/UPGRADE-2.0.md
- https://php.watch/articles/composer-2
2020-04-21 15:47:58 +02:00
Franz Liedke
c1db2b5a45 Format code
- Early returns
- Comments
- Write variables only when needed

Refs #2020.
2020-04-19 16:53:52 +02:00
Robert Korulczyk
9b925a5071 Load only translations for enabled extensions from language packs (#2020)
fix #1837

Co-authored-by: Daniel Klabbers <daniel+git@klabbers.email>
2020-04-19 16:29:45 +02:00
Franz Liedke
8b808bfc85 Inline test class
Refs #1977.
2020-04-19 15:55:10 +02:00
Clark Winkelmann
7143e13073 Make AbstractPolicy compatible with both object and class as $model (#1977) 2020-04-19 15:52:59 +02:00