@@ -112,6 +112,7 @@ interface SortableRowProps {
112112 isCollectionPublished : boolean ;
113113 children : React . ReactNode ;
114114 statusValue : import ( './CollectionStatusPill' ) . ItemStatusValue | null ;
115+ onEdit : ( ) => void ;
115116 onSetAsDraft : ( ) => void ;
116117 onStageForPublish : ( ) => void ;
117118 onSetAsPublished : ( ) => void ;
@@ -120,7 +121,7 @@ interface SortableRowProps {
120121 lockInfo ?: ItemLockInfo ;
121122}
122123
123- function SortableRow ( { item, isSaving, isManualMode, isCollectionPublished, children, statusValue, onSetAsDraft, onStageForPublish, onSetAsPublished, onDuplicate, onDelete, lockInfo } : SortableRowProps ) {
124+ function SortableRow ( { item, isSaving, isManualMode, isCollectionPublished, children, statusValue, onEdit , onSetAsDraft, onStageForPublish, onSetAsPublished, onDuplicate, onDelete, lockInfo } : SortableRowProps ) {
124125 const {
125126 attributes,
126127 listeners,
@@ -147,7 +148,9 @@ function SortableRow({ item, isSaving, isManualMode, isCollectionPublished, chil
147148 < CollectionItemContextMenu
148149 isPublishable = { statusValue ?. is_publishable ?? item . is_publishable }
149150 hasPublishedVersion = { statusValue ?. is_published ?? false }
151+ isModified = { statusValue ?. is_modified ?? false }
150152 isCollectionPublished = { isCollectionPublished }
153+ onEdit = { onEdit }
151154 onSetAsDraft = { onSetAsDraft }
152155 onStageForPublish = { onStageForPublish }
153156 onSetAsPublished = { onSetAsPublished }
@@ -1565,6 +1568,7 @@ const CMS = React.memo(function CMS() {
15651568 isManualMode = { isManualMode }
15661569 isCollectionPublished = { selectedCollection ?. has_published_version ?? false }
15671570 statusValue = { statusFieldId ? parseStatusValue ( item . values [ statusFieldId ] ) : null }
1571+ onEdit = { ( ) => handleEditItem ( item ) }
15681572 onSetAsDraft = { ( ) => handleSetItemStatus ( item . id , 'draft' ) }
15691573 onStageForPublish = { ( ) => handleSetItemStatus ( item . id , 'stage' ) }
15701574 onSetAsPublished = { ( ) => handleSetItemStatus ( item . id , 'publish' ) }
@@ -1576,9 +1580,7 @@ const CMS = React.memo(function CMS() {
15761580 className = "pl-5 pr-3 py-3 w-12"
15771581 onClick = { ( e ) => {
15781582 e . stopPropagation ( ) ;
1579- if ( ! isManualMode ) {
1580- handleEditItem ( item ) ;
1581- }
1583+ handleEditItem ( item ) ;
15821584 } }
15831585 >
15841586 < div className = "flex" >
@@ -1599,7 +1601,7 @@ const CMS = React.memo(function CMS() {
15991601 < td
16001602 key = { field . id }
16011603 className = "px-4 py-5"
1602- onClick = { ( ) => ! isManualMode && handleEditItem ( item ) }
1604+ onClick = { ( ) => handleEditItem ( item ) }
16031605 >
16041606 < CollectionStatusPill
16051607 statusValue = { statusFieldId ? parseStatusValue ( item . values [ statusFieldId ] ) : null }
@@ -1616,7 +1618,7 @@ const CMS = React.memo(function CMS() {
16161618 < td
16171619 key = { field . id }
16181620 className = "px-4 py-5 text-muted-foreground"
1619- onClick = { ( ) => ! isManualMode && handleEditItem ( item ) }
1621+ onClick = { ( ) => handleEditItem ( item ) }
16201622 >
16211623 < span className = "line-clamp-1 truncate" >
16221624 { formatDateInTimezone ( value , timezone , 'display' ) }
@@ -1637,7 +1639,7 @@ const CMS = React.memo(function CMS() {
16371639 < td
16381640 key = { field . id }
16391641 className = "px-4 py-5 text-muted-foreground"
1640- onClick = { ( ) => ! isManualMode && handleEditItem ( item ) }
1642+ onClick = { ( ) => handleEditItem ( item ) }
16411643 >
16421644 -
16431645 </ td >
@@ -1648,7 +1650,7 @@ const CMS = React.memo(function CMS() {
16481650 < td
16491651 key = { field . id }
16501652 className = "px-4"
1651- onClick = { ( ) => ! isManualMode && handleEditItem ( item ) }
1653+ onClick = { ( ) => handleEditItem ( item ) }
16521654 >
16531655 < div className = "flex items-center gap-1 -my-1.5" >
16541656 { assetIds . slice ( 0 , 3 ) . map ( ( assetId , idx ) => {
@@ -1716,7 +1718,7 @@ const CMS = React.memo(function CMS() {
17161718 < td
17171719 key = { field . id }
17181720 className = "px-4 py-5 text-muted-foreground"
1719- onClick = { ( ) => ! isManualMode && handleEditItem ( item ) }
1721+ onClick = { ( ) => handleEditItem ( item ) }
17201722 >
17211723 -
17221724 </ td >
@@ -1727,7 +1729,7 @@ const CMS = React.memo(function CMS() {
17271729 < td
17281730 key = { field . id }
17291731 className = "px-4"
1730- onClick = { ( ) => ! isManualMode && handleEditItem ( item ) }
1732+ onClick = { ( ) => handleEditItem ( item ) }
17311733 >
17321734 < div className = "flex items-center gap-1 -my-1.5" >
17331735 { assetIds . slice ( 0 , 3 ) . map ( ( assetId , idx ) => {
@@ -1763,7 +1765,7 @@ const CMS = React.memo(function CMS() {
17631765 < td
17641766 key = { field . id }
17651767 className = "px-4 py-5 text-muted-foreground"
1766- onClick = { ( ) => ! isManualMode && handleEditItem ( item ) }
1768+ onClick = { ( ) => handleEditItem ( item ) }
17671769 >
17681770
17691771 < ReferenceFieldCell
@@ -1783,7 +1785,7 @@ const CMS = React.memo(function CMS() {
17831785 < td
17841786 key = { field . id }
17851787 className = "px-4 py-5 text-muted-foreground max-w-50"
1786- onClick = { ( ) => ! isManualMode && handleEditItem ( item ) }
1788+ onClick = { ( ) => handleEditItem ( item ) }
17871789 >
17881790 < span className = "block truncate" >
17891791 { plainText || '-' }
@@ -1828,7 +1830,7 @@ const CMS = React.memo(function CMS() {
18281830 < td
18291831 key = { field . id }
18301832 className = "px-4 py-5 text-muted-foreground max-w-50"
1831- onClick = { ( ) => ! isManualMode && handleEditItem ( item ) }
1833+ onClick = { ( ) => handleEditItem ( item ) }
18321834 >
18331835 < span className = "block truncate" >
18341836 { displayValue }
@@ -1843,7 +1845,7 @@ const CMS = React.memo(function CMS() {
18431845 < td
18441846 key = { field . id }
18451847 className = "px-4 py-5 text-muted-foreground"
1846- onClick = { ( ) => ! isManualMode && handleEditItem ( item ) }
1848+ onClick = { ( ) => handleEditItem ( item ) }
18471849 >
18481850 < div className = "flex items-center gap-2" >
18491851 < div
@@ -1863,7 +1865,7 @@ const CMS = React.memo(function CMS() {
18631865 < td
18641866 key = { field . id }
18651867 className = "px-4 py-5"
1866- onClick = { ( ) => ! isManualMode && handleEditItem ( item ) }
1868+ onClick = { ( ) => handleEditItem ( item ) }
18671869 >
18681870 < div className = "pointer-events-none" >
18691871 < Checkbox
@@ -1880,7 +1882,7 @@ const CMS = React.memo(function CMS() {
18801882 < td
18811883 key = { field . id }
18821884 className = "px-4 py-5 text-muted-foreground"
1883- onClick = { ( ) => ! isManualMode && handleEditItem ( item ) }
1885+ onClick = { ( ) => handleEditItem ( item ) }
18841886 >
18851887 < span className = "line-clamp-1 truncate" >
18861888 { value || '-' }
0 commit comments