Skip to content

Commit

Permalink
Merge branch '4.x' into bugfix/admin-table-delete-footer-action-on-no…
Browse files Browse the repository at this point in the history
…n-endpoint-data

# Conflicts:
#	src/web/assets/admintable/dist/js/app.js
#	src/web/assets/admintable/dist/js/app.js.map
  • Loading branch information
nfourtythree committed Apr 30, 2024
2 parents 9e98b4c + 6d8ff8d commit cd27fcd
Show file tree
Hide file tree
Showing 13 changed files with 43 additions and 21 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Release Notes for Craft CMS 4

## 4.8.11 - 2024-04-29

- Fixed a bug where element caches weren’t getting invalidated when an element was moved within a structure. ([#14846](https://github.com/craftcms/cms/issues/14846))
- Fixed a bug where CSV’s header rows weren’t using the configured delimiter. ([#14855](https://github.com/craftcms/cms/issues/14855))
- Fixed a bug where editable table cell text styling could change after initial focus. ([#14857](https://github.com/craftcms/cms/issues/14857))
- Fixed a bug where conditions could list rules with duplicate labels.
- Fixed a bug where admin tables weren’t displaying disabled statuses. ([#14861](https://github.com/craftcms/cms/issues/14861))

## 4.8.10 - 2024-04-23

- Fixed a SQL error that could occur when converting a field to a Lightswitch field on PostgreSQL. ([#14792](https://github.com/craftcms/cms/issues/14792))
Expand Down
12 changes: 7 additions & 5 deletions packages/craftcms-vue/admintable/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -104,19 +104,21 @@
</template>
<template slot="title" slot-scope="props">
<span
v-if="props.rowData.status"
v-if="props.rowData.status !== undefined"
class="status"
:class="{enabled: props.rowData.status}"
></span>
<a
:class="{'cell-bold': !props.rowData.status}"
:class="{'cell-bold': props.rowData.status === undefined}"
v-if="props.rowData.url"
:href="props.rowData.url"
>{{ props.rowData.title }}</a
>
<span :class="{'cell-bold': !props.rowData.status}" v-else>{{
props.rowData.title
}}</span>
<span
:class="{'cell-bold': props.rowData.status === undefined}"
v-else
>{{ props.rowData.title }}</span
>
</template>

<template slot="handle" slot-scope="props">
Expand Down
7 changes: 4 additions & 3 deletions src/base/conditions/BaseCondition.php
Original file line number Diff line number Diff line change
Expand Up @@ -460,18 +460,19 @@ private function _ruleTypeMenu(
$labelsByGroup = [];

if ($rule) {
$ruleLabel = $rule->getLabel();
$label = $rule->getLabel();
$hint = $rule->getLabelHint();
$key = $label . ($hint !== null ? " - $hint" : '');
$groupLabel = $rule->getGroupLabel() ?? '__UNGROUPED__';

$groupedRuleTypeOptions[$groupLabel] = [
[
'label' => $ruleLabel,
'label' => $label,
'hint' => $hint,
'value' => $ruleValue,
],
];
$labelsByGroup[$groupLabel][$hint] = true;
$labelsByGroup[$groupLabel][$key] = true;
}

foreach ($selectableRules as $value => $selectableRule) {
Expand Down
2 changes: 1 addition & 1 deletion src/config/app.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
return [
'id' => 'CraftCMS',
'name' => 'Craft CMS',
'version' => '4.8.10',
'version' => '4.8.11',
'schemaVersion' => '4.5.3.0',
'minVersionRequired' => '3.7.11',
'basePath' => dirname(__DIR__), // Defines the @app alias
Expand Down
6 changes: 3 additions & 3 deletions src/elements/db/EntryQuery.php
Original file line number Diff line number Diff line change
Expand Up @@ -707,9 +707,9 @@ public function before(mixed $value): self
*
* | Value | Fetches entries…
* | - | -
* | `'2018-04-01'` | that were posted after 2018-04-01.
* | a [[\DateTime|DateTime]] object | that were posted after the date represented by the object.
* | `now`/`today`/`tomorrow`/`yesterday` | that were posted after midnight of the specified relative date.
* | `'2018-04-01'` | that were posted on or after 2018-04-01.
* | a [[\DateTime|DateTime]] object | that were posted on or after the date represented by the object.
* | `now`/`today`/`tomorrow`/`yesterday` | that were posted on or after midnight of the specified relative date.
*
* ---
*
Expand Down
4 changes: 4 additions & 0 deletions src/services/Structures.php
Original file line number Diff line number Diff line change
Expand Up @@ -599,6 +599,10 @@ private function _doIt(int $structureId, ElementInterface $element, StructureEle
throw $e;
}

// Invalidate all caches for the element type
// (see https://github.com/craftcms/cms/issues/14846)
Craft::$app->getElements()->invalidateCachesForElementType($element::class);

if ($this->hasEventHandlers($afterEvent)) {
// Fire an 'afterMoveElement' event
$this->trigger($afterEvent, new MoveElementEvent([
Expand Down
2 changes: 1 addition & 1 deletion src/translations/zh/app.php

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

2 changes: 1 addition & 1 deletion src/web/CsvResponseFormatter.php
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ public function format($response): void
}

if ($this->includeHeaderRow) {
fputcsv($fp, $headers, ',');
fputcsv($fp, $headers, $this->delimiter);
}

foreach ($data as &$row) {
Expand Down
2 changes: 1 addition & 1 deletion src/web/assets/admintable/dist/js/app.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/web/assets/admintable/dist/js/app.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/web/assets/cp/dist/css/cp.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/web/assets/cp/dist/css/cp.css.map

Large diffs are not rendered by default.

13 changes: 10 additions & 3 deletions src/web/assets/cp/src/css/_main.scss
Original file line number Diff line number Diff line change
Expand Up @@ -388,16 +388,22 @@ ol {

/* code */
code,
.code,
.code input,
.code textarea {
.code {
@include fixed-width-font;

&.smalltext {
font-size: 0.8em !important;
}
}

.code {
input,
textarea {
@include fixed-width-font;
font-size: 1em !important;
}
}

pre code {
display: block;
overflow-x: auto;
Expand Down Expand Up @@ -3684,6 +3690,7 @@ table.editable {
box-shadow: none;
border-radius: 0;
padding: 7px 10px;
line-height: 20px;
background-color: transparent;
overflow: hidden;
transition: none;
Expand Down

0 comments on commit cd27fcd

Please sign in to comment.