Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove checkbox from preview view #920

Merged
merged 2 commits into from
Jan 23, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 2 additions & 15 deletions assets/js/src/core/components/preview-card/preview-card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
* @license https://github.com/pimcore/studio-ui-bundle/blob/1.x/LICENSE.md POCL and PCL
*/

import { Button, Card, Checkbox, type MenuRef } from 'antd'
import React, { useRef, useState } from 'react'
import { Button, Card, type MenuRef } from 'antd'
import React, { useRef } from 'react'
import { useStyle } from './preview-card.styles'
import Meta from 'antd/es/card/Meta'
import { Icon } from '../icon/icon'
Expand All @@ -35,26 +35,19 @@ interface PreviewCardProps {
export const PreviewCard = (props: PreviewCardProps): React.JSX.Element => {
const { size = SizeTypes.SMALL } = props
const { styles } = useStyle()
const [selected, setSelected] = useState(false)
const dropdownMenuRef = useRef<MenuRef>(null)

let classCard: string = ''
let classImg: string = 'img'
let classImgDiv: string = 'img-container'
let classCheckbox: string = 'checkbox'
let classDotsButton: string = 'dots-button'
if (size === SizeTypes.MEDIUM) {
classCard = 'card-medium'
classImg = 'img-medium'
classImgDiv = 'img-container-medium'
classCheckbox = 'checkbox-medium'
classDotsButton = 'dots-button-medium'
}

const onChangeSelection = (e): void => {
setSelected(!selected)
}

return (
<Card
className={ [styles.card, classCard].join(' ') }
Expand All @@ -76,12 +69,6 @@ export const PreviewCard = (props: PreviewCardProps): React.JSX.Element => {
}
} }
>
<Checkbox
checked={ selected }
className={ classCheckbox }
onChange={ onChangeSelection }
onClick={ (e) => { e.stopPropagation() } }
/>
<Dropdown
menu={ {
items: props.dropdownItems
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"entrypoints": {
"vendor": {
"js": [
"/bundles/pimcorestudioui/build/11a5fc86-892b-46bc-b647-75613b485421/vendor.js"
]
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"bundles/pimcorestudioui/build/11a5fc86-892b-46bc-b647-75613b485421/vendor.js": "/bundles/pimcorestudioui/build/11a5fc86-892b-46bc-b647-75613b485421/vendor.js"
}

Large diffs are not rendered by default.

Large diffs are not rendered by default.

12 changes: 12 additions & 0 deletions public/build/19391804-d197-4736-a0de-6184faafcc0c/entrypoints.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"entrypoints": {
"core-dll": {
"css": [
"/bundles/pimcorestudioui/build/19391804-d197-4736-a0de-6184faafcc0c/core-dll.css"
],
"js": [
"/bundles/pimcorestudioui/build/19391804-d197-4736-a0de-6184faafcc0c/core-dll.js"
]
}
}
}

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"entrypoints": {
"main": {
"js": [
"/bundles/pimcorestudioui/build/2605d36f-e728-4f51-bc97-bc5130b3b6a8/main.js"
]
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"bundles/pimcorestudioui/build/2605d36f-e728-4f51-bc97-bc5130b3b6a8/main.js": "/bundles/pimcorestudioui/build/2605d36f-e728-4f51-bc97-bc5130b3b6a8/main.js"
}
12 changes: 0 additions & 12 deletions public/build/736ca9c5-de00-430e-b107-eb8a21060e15/entrypoints.json

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Loading