From f278cfd3bb7b23e8734c4076d36969d026c9b9a0 Mon Sep 17 00:00:00 2001 From: Michael An <2331806369@qq.com> Date: Mon, 18 Sep 2023 10:01:30 +0800 Subject: [PATCH] Change select style (#5645) * 01 change css file path * 02 change Select style --- .../src/components/common/notification.js | 2 +- .../src/components/common/select/index.js | 5 + .../common/select/no-group-message.js | 15 +++ .../common/select/seahub-select-style.js | 49 ++++++++ .../components/common/select/seahub-select.js | 110 ++++++++++++++++++ .../components/dialog/create-repo-dialog.js | 12 +- ...-sub-folder-set-group-permission-dialog.js | 17 +-- .../src/components/dialog/share-to-group.js | 18 +-- .../dialog/share-to-other-server.js | 7 +- .../sysadmin-share-to-group.js | 18 +-- .../src/components/dialog/transfer-dialog.js | 5 +- .../repo-api-token-permission-editor.js | 4 +- .../components/select-editor/select-editor.js | 24 +--- frontend/src/components/user-select.js | 2 + .../user-settings/language-setting.js | 4 +- .../common => css}/notification.css | 0 16 files changed, 206 insertions(+), 86 deletions(-) create mode 100644 frontend/src/components/common/select/index.js create mode 100644 frontend/src/components/common/select/no-group-message.js create mode 100644 frontend/src/components/common/select/seahub-select-style.js create mode 100644 frontend/src/components/common/select/seahub-select.js rename frontend/src/{components/common => css}/notification.css (100%) diff --git a/frontend/src/components/common/notification.js b/frontend/src/components/common/notification.js index 9d57c828d4..ed318ce0ce 100644 --- a/frontend/src/components/common/notification.js +++ b/frontend/src/components/common/notification.js @@ -5,7 +5,7 @@ import { gettext } from '../../utils/constants'; import NoticeItem from './notice-item'; import UserNotificationsDialog from '../../user-notifications'; import { Utils } from '../../utils/utils'; -import './notification.css'; +import '../../css/notification.css'; class Notification extends React.Component { constructor(props) { diff --git a/frontend/src/components/common/select/index.js b/frontend/src/components/common/select/index.js new file mode 100644 index 0000000000..17d8a9bfe1 --- /dev/null +++ b/frontend/src/components/common/select/index.js @@ -0,0 +1,5 @@ +import SeahubSelect from './seahub-select'; +import { NoGroupMessage } from './no-group-message'; +import { MenuSelectStyle, UserSelectStyle } from './seahub-select-style'; + +export { SeahubSelect, NoGroupMessage, MenuSelectStyle, UserSelectStyle }; diff --git a/frontend/src/components/common/select/no-group-message.js b/frontend/src/components/common/select/no-group-message.js new file mode 100644 index 0000000000..7a9abcc9fa --- /dev/null +++ b/frontend/src/components/common/select/no-group-message.js @@ -0,0 +1,15 @@ +import React from 'react'; +import PropTypes from 'prop-types'; +import { gettext } from '../../../utils/constants'; + +const NoGroupMessage = (props) => { + return ( +