Skip to content

Commit

Permalink
Merge branch '5.x' into fix/taxonomy-url
Browse files Browse the repository at this point in the history
  • Loading branch information
jasonvarga committed Sep 27, 2024
2 parents ee48dff + 4731d57 commit 9d6028b
Show file tree
Hide file tree
Showing 477 changed files with 15,012 additions and 2,465 deletions.
2 changes: 1 addition & 1 deletion .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Please take 30 seconds to read the following so we can be as efficient as possib

2️⃣ Please make sure to create a new branch for your PR.

3️⃣ Typically you should target the branch of the most current release, e.g. `4.x`, unless your PR includes a breaking change, in which case you should target the `master` branch for the next major release.
3️⃣ Typically you should target the branch of the most current release, e.g. `5.x`, unless your PR includes a breaking change, in which case you should target the `master` branch for the next major release.

4️⃣ We _really_ appreciate it if your PR includes tests. This makes it much easier for us to review, merge, and release. A PR with tests is usually reviewed and merged 5x-10x faster.

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ jobs:
uses: tj-actions/changed-files@v44
with:
files: |
**.{js,vue,ts}
**/*.{js,vue,ts}
package.json
.github/workflows/tests.yml
Expand Down
295 changes: 295 additions & 0 deletions CHANGELOG.md

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion SECURITY.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ While working to identify potential security vulnerabilities in Statamic, we ask
- Provide a quality report with precise explanations and concrete attack scenarios.

## Scope
We are only interested in vulnerabilities that affect Statamic itself, tested against **your own local installation** of the software, running the latest version. You can install a local copy of Statamic by following these [installation instructions](https://statamic.dev/installing). Do not test against any Statamic installation that you don’t own, including [statamic.com](https:/statamic.com) or [statamic.dev](https://statamic.dev).
We are only interested in vulnerabilities that affect Statamic itself, tested against **your own local installation** of the software, running the latest version. You can install a local copy of Statamic by following these [installation instructions](https://statamic.dev/installing). Do not test against any Statamic installation that you don’t own, including [statamic.com](https:/statamic.com), [statamic.dev](https://statamic.dev), and [demo.statamic.com](https://demo.statamic.com).

### Potentially Qualifying Vulnerabilities

Expand Down
5 changes: 3 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"symfony/lock": "^6.4",
"symfony/var-exporter": "^6.0",
"symfony/yaml": "^6.0 || ^7.0",
"ueberdosis/tiptap-php": "^1.1",
"ueberdosis/tiptap-php": "^1.4",
"voku/portable-ascii": "^2.0",
"wilderborn/partyline": "^1.0"
},
Expand All @@ -42,7 +42,8 @@
"laravel/pint": "1.16.0",
"mockery/mockery": "^1.3.3",
"orchestra/testbench": "^8.14 || ^9.0",
"phpunit/phpunit": "^10.0"
"phpunit/phpunit": "^10.0",
"spatie/laravel-ray": "^1.37"
},
"config": {
"optimize-autoloader": true,
Expand Down
1 change: 1 addition & 0 deletions config/protect.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
'password' => [
'driver' => 'password',
'allowed' => ['secret'],
'field' => null,
'form_url' => null,
],

Expand Down
23 changes: 23 additions & 0 deletions config/static_caching.php
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,29 @@

'ignore_query_strings' => false,

'allowed_query_strings' => [
//
],

'disallowed_query_strings' => [
//
],

/*
|--------------------------------------------------------------------------
| Nocache
|--------------------------------------------------------------------------
|
| Here you may define where the nocache data is stored.
|
| https://statamic.dev/tags/nocache#database
|
| Supported drivers: "cache", "database"
|
*/

'nocache' => 'cache',

/*
|--------------------------------------------------------------------------
| Replacers
Expand Down
2 changes: 1 addition & 1 deletion config/system.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
|--------------------------------------------------------------------------
|
| The license key for the corresponding domain from your Statamic account.
| Without a key entered, your app will considered to be in Trial Mode.
| Without a key entered, your app will be considered to be in Trial Mode.
|
| https://statamic.dev/licensing#trial-mode
|
Expand Down
24 changes: 12 additions & 12 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"@tiptap/vue-2": "^2.0.2",
"alpinejs": "^3.1.1",
"autosize": "~3.0.12",
"axios": "^1.6.0",
"axios": "^1.7.4",
"body-scroll-lock": "^4.0.0-beta.0",
"codemirror": "^5.58.2",
"cookies-js": "^1.2.2",
Expand Down Expand Up @@ -98,6 +98,6 @@
"laravel-vite-plugin": "^0.7.2",
"postcss": "^8.4.31",
"tailwindcss": "^3.3.0",
"vite": "^4.5.3"
"vite": "^4.5.5"
}
}
4 changes: 4 additions & 0 deletions resources/css/components/assets.css
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,10 @@

}

.assets-fieldtype-picker + .asset-table-listing {
@apply rounded-t-none;
}

.asset-listing .actions {
margin-bottom: 15px;
display: flex;
Expand Down
2 changes: 1 addition & 1 deletion resources/css/components/fieldtypes/assets.css
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
}

.assets-fieldtype .assets-fieldtype-picker {
@apply flex flex-col @sm:flex-row items-start @sm:items-center px-4 py-2 bg-gray-200 dark:bg-dark-650 border dark:border-dark-900 rounded;
@apply flex items-center px-4 py-2 bg-gray-200 dark:bg-dark-650 border dark:border-dark-900 rounded;

&.is-expanded {
@apply border-b-0 rounded-b-none;
Expand Down
18 changes: 17 additions & 1 deletion resources/css/components/fieldtypes/bard.css
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,23 @@
h1, h2, h3, h4, h5, h6 {
margin-top: 1.275em;
margin-bottom: .85em;
font-weight: 700
font-weight: 700;

b,
strong {
font-weight: 900;
}

a {
@apply text-blue dark:text-dark-blue-100 underline break-words;
}

a:active,
a:focus,
a:hover {
outline: 0;
text-decoration: underline;
}
}

h1 { font-size: 2em }
Expand Down
4 changes: 4 additions & 0 deletions resources/css/components/fieldtypes/datetime.css
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@
@apply border-none bg-none;
}

.vc-container.vc-is-dark {
@apply dark:bg-transparent;
}

/* Time Field
========================================================================== */

Expand Down
20 changes: 20 additions & 0 deletions resources/css/components/fieldtypes/dictionary-fields.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
.dictionary_fields-fieldtype {
@apply p-0;

.publish-fields {
@apply w-full;
}

.config-field {
@apply md:flex flex-wrap border-b border-gray-400 dark:border-dark-900 w-full;
@apply p-3 @sm:p-4 m-0;

.field-inner {
@apply w-full md:w-1/2 rtl:md:pl-8 ltr:md:pr-8;
}

.field-inner + div {
@apply w-full md:w-1/2;
}
}
}
1 change: 1 addition & 0 deletions resources/css/cp.css
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@
@import "components/fieldtypes/checkboxes";
@import "components/fieldtypes/code";
@import "components/fieldtypes/datetime";
@import "components/fieldtypes/dictionary-fields";
@import "components/fieldtypes/environment";
@import "components/fieldtypes/grid";
@import "components/fieldtypes/hidden";
Expand Down
4 changes: 2 additions & 2 deletions resources/css/elements/buttons.css
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ button {

/* Earth isn't flat but these buttons are */
.btn-flat {
@apply text-white text-gray-800 dark:text-dark-150 bg-gray-300 dark:bg-dark-700 flex items-center;
@apply text-gray-800 dark:text-dark-150 bg-gray-300 dark:bg-dark-700 flex items-center;
position: inherit;

&:hover:not(:disabled), &:active:not(:disabled), &.active {
Expand Down Expand Up @@ -296,7 +296,7 @@ td .btn-icon {
@apply dark:hover:bg-dark-575 dark:hover:border-dark-400;

svg {
@apply h-8 w-8 text-gray-800 dark:text-dark-175;
@apply h-8 w-8 text-gray-800 dark:text-dark-200;
}

h3 {
Expand Down
2 changes: 1 addition & 1 deletion resources/css/elements/forms.css
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ select {
========================================================================== */

.input-text {
@apply appearance-none bg-gray-100 text-gray-800 border max-w-full w-full p-2 rounded shadow-inner placeholder:text-gray-600 text-md @lg:text-base;
@apply block appearance-none bg-gray-100 text-gray-800 border max-w-full w-full p-2 rounded shadow-inner placeholder:text-gray-600 text-md @lg:text-base;
@apply dark:bg-dark-650 dark:text-dark-150 dark:border-dark-900 dark:placeholder:text-dark-175 dark:shadow-inner-dark;
transition: border-color .15s ease-in-out,
box-shadow .15s ease-in-out;
Expand Down
2 changes: 1 addition & 1 deletion resources/css/elements/icons.css
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ svg {
flex-shrink: 0;

&.published { @apply bg-green-600 }
&.draft, &.expired { @apply bg-gray-600 }
&.draft, &.expired { @apply bg-gray-600 dark:bg-dark-200 }
&.scheduled, &.hollow { @apply bg-transparent border border-gray-600 }
}

Expand Down
6 changes: 6 additions & 0 deletions resources/css/vendors/vue-select.css
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,12 @@

&.sortable-item { @apply !cursor-grab; }

&.invalid {
@apply border-red-300 dark:border-dark-red bg-red-100 dark:bg-red-400 text-red-500 dark:text-red-950;
background-image: none;

.vs__deselect { @apply text-red-500 dark:text-red-950 }
}
}

.vs__deselect {
Expand Down
8 changes: 6 additions & 2 deletions resources/js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,8 @@ Statamic.app({
showBanner: true,
portals: [],
appendedComponents: [],
isLicensingBannerSnoozed: localStorage.getItem(`statamic.snooze_license_banner`) > new Date().valueOf(),
copyToClipboardModalUrl: null,
},

computed: {
Expand Down Expand Up @@ -242,12 +244,13 @@ Statamic.app({

this.fixAutofocus();

this.showBanner = Statamic.$config.get('hasLicenseBanner');
this.showBanner = !this.isLicensingBannerSnoozed && Statamic.$config.get('hasLicenseBanner');

this.$toast.intercept();
},

created() {
const app = this;
const state = localStorage.getItem('statamic.nav') || 'open';
this.navOpen = state === 'open';

Expand All @@ -256,7 +259,7 @@ Statamic.app({
await navigator.clipboard.writeText(url);
Statamic.$toast.success(__('Copied to clipboard'));
} catch (err) {
await alert(url);
app.copyToClipboardModalUrl = url;
}
});

Expand Down Expand Up @@ -292,6 +295,7 @@ Statamic.app({

hideBanner() {
this.showBanner = false;
localStorage.setItem(`statamic.snooze_license_banner`, new Date(Date.now() + 5 * 60 * 1000).valueOf());
},

fixAutofocus() {
Expand Down
3 changes: 3 additions & 0 deletions resources/js/bootstrap/components.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ import ResourceDeleter from '../components/ResourceDeleter.vue';
import Stack from '../components/stacks/Stack.vue';
import StackTest from '../components/stacks/StackTest.vue';
import CodeBlock from '../components/CodeBlock.vue';
import BlueprintResetter from '../components/blueprints/BlueprintResetter.vue';

// Third Party
Vue.component('v-select', vSelect)
Expand Down Expand Up @@ -142,3 +143,5 @@ Vue.component('resource-deleter', ResourceDeleter);

Vue.component('stack', Stack);
Vue.component('stack-test', StackTest);

Vue.component('blueprint-resetter', BlueprintResetter);
4 changes: 4 additions & 0 deletions resources/js/bootstrap/fieldtypes.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ import Routes from '../components/collections/Routes.vue';
import TitleFormats from '../components/collections/TitleFormats.vue';
import ColorFieldtype from '../components/fieldtypes/ColorFieldtype.vue';
import DateFieldtype from '../components/fieldtypes/DateFieldtype.vue';
import DictionaryFieldtype from "../components/fieldtypes/DictionaryFieldtype.vue";
import DictionaryFields from "../components/fieldtypes/DictionaryFields.vue";
import FieldDisplayFieldtype from '../components/fieldtypes/FieldDisplayFieldtype.vue';
import FieldsFieldtype from '../components/fieldtypes/grid/FieldsFieldtype.vue';
import FilesFieldtype from '../components/fieldtypes/FilesFieldtype.vue';
Expand Down Expand Up @@ -86,6 +88,8 @@ Vue.component('collection_routes-fieldtype', Routes);
Vue.component('collection_title_formats-fieldtype', TitleFormats);
Vue.component('color-fieldtype', ColorFieldtype);
Vue.component('date-fieldtype', DateFieldtype);
Vue.component('dictionary-fieldtype', DictionaryFieldtype);
Vue.component('dictionary_fields-fieldtype', DictionaryFields);
Vue.component('field_display-fieldtype', FieldDisplayFieldtype);
Vue.component('fields-fieldtype', FieldsFieldtype);
Vue.component('files-fieldtype', FilesFieldtype);
Expand Down
Loading

0 comments on commit 9d6028b

Please sign in to comment.