fix: collection permission check (#7171)
This commit is contained in:
@@ -18,6 +18,7 @@ import Switch from "~/components/Switch";
|
|||||||
import Text from "~/components/Text";
|
import Text from "~/components/Text";
|
||||||
import useBoolean from "~/hooks/useBoolean";
|
import useBoolean from "~/hooks/useBoolean";
|
||||||
import useCurrentTeam from "~/hooks/useCurrentTeam";
|
import useCurrentTeam from "~/hooks/useCurrentTeam";
|
||||||
|
import { EmptySelectValue } from "~/types";
|
||||||
import { Feature, FeatureFlags } from "~/utils/FeatureFlags";
|
import { Feature, FeatureFlags } from "~/utils/FeatureFlags";
|
||||||
|
|
||||||
const IconPicker = React.lazy(() => import("~/components/IconPicker"));
|
const IconPicker = React.lazy(() => import("~/components/IconPicker"));
|
||||||
@@ -142,8 +143,10 @@ export const CollectionForm = observer(function CollectionForm_({
|
|||||||
<InputSelectPermission
|
<InputSelectPermission
|
||||||
ref={field.ref}
|
ref={field.ref}
|
||||||
value={field.value}
|
value={field.value}
|
||||||
onChange={(value: CollectionPermission) => {
|
onChange={(
|
||||||
field.onChange(value);
|
value: CollectionPermission | typeof EmptySelectValue
|
||||||
|
) => {
|
||||||
|
field.onChange(value === EmptySelectValue ? null : value);
|
||||||
}}
|
}}
|
||||||
note={t(
|
note={t(
|
||||||
"The default access for workspace members, you can share with more users or groups later."
|
"The default access for workspace members, you can share with more users or groups later."
|
||||||
|
|||||||
Reference in New Issue
Block a user