@wordpress/edit-site 6.27.1-next.46f643fa0.0 → 6.28.1-next.0f6f9d12c.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (54) hide show
  1. package/CHANGELOG.md +2 -0
  2. package/build/components/media/index.js +1 -1
  3. package/build/components/media/index.js.map +1 -1
  4. package/build/components/page-templates/fields.js +1 -4
  5. package/build/components/page-templates/fields.js.map +1 -1
  6. package/build/components/page-templates/hooks.js +1 -2
  7. package/build/components/page-templates/hooks.js.map +1 -1
  8. package/build/components/page-templates/index.js +1 -8
  9. package/build/components/page-templates/index.js.map +1 -1
  10. package/build/components/post-edit/index.js +10 -4
  11. package/build/components/post-edit/index.js.map +1 -1
  12. package/build/components/post-list/index.js +1 -30
  13. package/build/components/post-list/index.js.map +1 -1
  14. package/build/components/sidebar-dataviews/default-views.js +53 -37
  15. package/build/components/sidebar-dataviews/default-views.js.map +1 -1
  16. package/build/components/style-book/index.js +2 -2
  17. package/build/components/style-book/index.js.map +1 -1
  18. package/build/store/selectors.js +1 -1
  19. package/build/store/selectors.js.map +1 -1
  20. package/build-module/components/media/index.js +1 -1
  21. package/build-module/components/media/index.js.map +1 -1
  22. package/build-module/components/page-templates/fields.js +1 -4
  23. package/build-module/components/page-templates/fields.js.map +1 -1
  24. package/build-module/components/page-templates/hooks.js +1 -2
  25. package/build-module/components/page-templates/hooks.js.map +1 -1
  26. package/build-module/components/page-templates/index.js +1 -8
  27. package/build-module/components/page-templates/index.js.map +1 -1
  28. package/build-module/components/post-edit/index.js +10 -4
  29. package/build-module/components/post-edit/index.js.map +1 -1
  30. package/build-module/components/post-list/index.js +1 -30
  31. package/build-module/components/post-list/index.js.map +1 -1
  32. package/build-module/components/sidebar-dataviews/default-views.js +53 -37
  33. package/build-module/components/sidebar-dataviews/default-views.js.map +1 -1
  34. package/build-module/components/style-book/index.js +2 -2
  35. package/build-module/components/style-book/index.js.map +1 -1
  36. package/build-module/store/selectors.js +1 -1
  37. package/build-module/store/selectors.js.map +1 -1
  38. package/build-style/posts-rtl.css +78 -24
  39. package/build-style/posts.css +78 -24
  40. package/build-style/style-rtl.css +112 -51
  41. package/build-style/style.css +112 -51
  42. package/package.json +42 -42
  43. package/src/components/global-styles-sidebar/style.scss +0 -19
  44. package/src/components/media/index.js +1 -1
  45. package/src/components/page-templates/fields.js +1 -7
  46. package/src/components/page-templates/hooks.js +7 -7
  47. package/src/components/page-templates/index.js +0 -7
  48. package/src/components/page-templates/style.scss +0 -12
  49. package/src/components/post-edit/index.js +10 -4
  50. package/src/components/post-list/index.js +1 -42
  51. package/src/components/sidebar-dataviews/default-views.js +63 -47
  52. package/src/components/style-book/index.js +2 -2
  53. package/src/store/selectors.js +1 -1
  54. package/tsconfig.tsbuildinfo +1 -1
@@ -69,66 +69,81 @@ export function useDefaultViews( { postType } ) {
69
69
  title: __( 'Published' ),
70
70
  slug: 'published',
71
71
  icon: published,
72
- view: DEFAULT_POST_BASE,
73
- filters: [
74
- {
75
- field: 'status',
76
- operator: OPERATOR_IS_ANY,
77
- value: 'publish',
78
- },
79
- ],
72
+ view: {
73
+ ...DEFAULT_POST_BASE,
74
+ filters: [
75
+ {
76
+ field: 'status',
77
+ operator: OPERATOR_IS_ANY,
78
+ value: 'publish',
79
+ isLocked: true,
80
+ },
81
+ ],
82
+ },
80
83
  },
81
84
  {
82
85
  title: __( 'Scheduled' ),
83
86
  slug: 'future',
84
87
  icon: scheduled,
85
- view: DEFAULT_POST_BASE,
86
- filters: [
87
- {
88
- field: 'status',
89
- operator: OPERATOR_IS_ANY,
90
- value: 'future',
91
- },
92
- ],
88
+ view: {
89
+ ...DEFAULT_POST_BASE,
90
+ filters: [
91
+ {
92
+ field: 'status',
93
+ operator: OPERATOR_IS_ANY,
94
+ value: 'future',
95
+ isLocked: true,
96
+ },
97
+ ],
98
+ },
93
99
  },
94
100
  {
95
101
  title: __( 'Drafts' ),
96
102
  slug: 'drafts',
97
103
  icon: drafts,
98
- view: DEFAULT_POST_BASE,
99
- filters: [
100
- {
101
- field: 'status',
102
- operator: OPERATOR_IS_ANY,
103
- value: 'draft',
104
- },
105
- ],
104
+ view: {
105
+ ...DEFAULT_POST_BASE,
106
+ filters: [
107
+ {
108
+ field: 'status',
109
+ operator: OPERATOR_IS_ANY,
110
+ value: 'draft',
111
+ isLocked: true,
112
+ },
113
+ ],
114
+ },
106
115
  },
107
116
  {
108
117
  title: __( 'Pending' ),
109
118
  slug: 'pending',
110
119
  icon: pending,
111
- view: DEFAULT_POST_BASE,
112
- filters: [
113
- {
114
- field: 'status',
115
- operator: OPERATOR_IS_ANY,
116
- value: 'pending',
117
- },
118
- ],
120
+ view: {
121
+ ...DEFAULT_POST_BASE,
122
+ filters: [
123
+ {
124
+ field: 'status',
125
+ operator: OPERATOR_IS_ANY,
126
+ value: 'pending',
127
+ isLocked: true,
128
+ },
129
+ ],
130
+ },
119
131
  },
120
132
  {
121
133
  title: __( 'Private' ),
122
134
  slug: 'private',
123
135
  icon: notAllowed,
124
- view: DEFAULT_POST_BASE,
125
- filters: [
126
- {
127
- field: 'status',
128
- operator: OPERATOR_IS_ANY,
129
- value: 'private',
130
- },
131
- ],
136
+ view: {
137
+ ...DEFAULT_POST_BASE,
138
+ filters: [
139
+ {
140
+ field: 'status',
141
+ operator: OPERATOR_IS_ANY,
142
+ value: 'private',
143
+ isLocked: true,
144
+ },
145
+ ],
146
+ },
132
147
  },
133
148
  {
134
149
  title: __( 'Trash' ),
@@ -138,14 +153,15 @@ export function useDefaultViews( { postType } ) {
138
153
  ...DEFAULT_POST_BASE,
139
154
  type: LAYOUT_TABLE,
140
155
  layout: defaultLayouts[ LAYOUT_TABLE ].layout,
156
+ filters: [
157
+ {
158
+ field: 'status',
159
+ operator: OPERATOR_IS_ANY,
160
+ value: 'trash',
161
+ isLocked: true,
162
+ },
163
+ ],
141
164
  },
142
- filters: [
143
- {
144
- field: 'status',
145
- operator: OPERATOR_IS_ANY,
146
- value: 'trash',
147
- },
148
- ],
149
165
  },
150
166
  ];
151
167
  }, [ labels ] );
@@ -393,8 +393,8 @@ export const StyleBookPreview = ( { userConfig = {}, isStatic = false } ) => {
393
393
  const canUserUploadMedia = useSelect(
394
394
  ( select ) =>
395
395
  select( coreStore ).canUser( 'create', {
396
- kind: 'root',
397
- name: 'media',
396
+ kind: 'postType',
397
+ name: 'attachment',
398
398
  } ),
399
399
  []
400
400
  );
@@ -79,7 +79,7 @@ export const getCanUserCreateMedia = createRegistrySelector(
79
79
  `wp.data.select( 'core/edit-site' ).getCanUserCreateMedia()`,
80
80
  {
81
81
  since: '6.7',
82
- alternative: `wp.data.select( 'core' ).canUser( 'create', { kind: 'root', type: 'media' } )`,
82
+ alternative: `wp.data.select( 'core' ).canUser( 'create', { kind: 'postType', type: 'attachment' } )`,
83
83
  }
84
84
  );
85
85