mirror of
https://github.com/casdoor/casdoor.git
synced 2025-07-04 05:10:19 +08:00
Add one tooltip.
This commit is contained in:
@ -101,7 +101,7 @@ class ApplicationEditPage extends React.Component {
|
||||
} style={{marginLeft: '5px'}} type="inner">
|
||||
<Row style={{marginTop: '10px'}} >
|
||||
<Col style={{marginTop: '5px'}} span={2}>
|
||||
{i18next.t("general:Name")}:
|
||||
{Setting.getLabel(i18next.t("general:Name"), i18next.t("general:Name - Tooltip"))} :
|
||||
</Col>
|
||||
<Col span={22} >
|
||||
<Input value={this.state.application.name} onChange={e => {
|
||||
|
@ -12,7 +12,8 @@
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
import {message} from "antd";
|
||||
import {message, Tooltip} from "antd";
|
||||
import {QuestionCircleTwoTone} from "@ant-design/icons";
|
||||
import React from "react";
|
||||
import {isMobile as isMobileDevice} from "react-device-detect";
|
||||
import "./i18n";
|
||||
@ -408,3 +409,14 @@ export function renderHelmet(application) {
|
||||
</Helmet>
|
||||
)
|
||||
}
|
||||
|
||||
export function getLabel(text, tooltip) {
|
||||
return (
|
||||
<React.Fragment>
|
||||
<span style={{ marginRight: 4 }}>{text}</span>
|
||||
<Tooltip placement="top" title={tooltip}>
|
||||
<QuestionCircleTwoTone twoToneColor="rgb(45,120,213)" />
|
||||
</Tooltip>
|
||||
</React.Fragment>
|
||||
);
|
||||
}
|
||||
|
@ -18,6 +18,7 @@
|
||||
"Organization": "Organization",
|
||||
"Created time": "Created time",
|
||||
"Name": "Name",
|
||||
"Name - Tooltip": "Unique string-style identifier",
|
||||
"Display name": "Display name",
|
||||
"Personal name": "Personal name",
|
||||
"Avatar": "Avatar",
|
||||
|
@ -18,6 +18,7 @@
|
||||
"Organization": "组织",
|
||||
"Created time": "创建时间",
|
||||
"Name": "名称",
|
||||
"Name - Tooltip": "唯一的、字符串式的ID",
|
||||
"Display name": "显示名称",
|
||||
"Personal name": "姓名",
|
||||
"Avatar": "头像",
|
||||
|
Reference in New Issue
Block a user