Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Aug 5, 2025. It is now read-only.

Commit e3cdce4

Browse files
committed
chore
1 parent 6279bbe commit e3cdce4

File tree

2 files changed

+15
-13
lines changed

2 files changed

+15
-13
lines changed

‎packages/plugin-browser-hint/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@alicloud/console-toolkit-plugin-browser-hint",
3-
"version": "1.2.30",
3+
"version": "1.2.32",
44
"description": "console toolkit plugin for browser hint",
55
"main": "lib/index.js",
66
"scripts": {
@@ -27,7 +27,7 @@
2727
"ts-jest": "^24.0.0",
2828
"ts-node": "^8.4.1",
2929
"tslint": "^5.8.0",
30-
"typescript": "^3.0.3"
30+
"typescript": "^4.9.5"
3131
},
3232
"dependencies": {
3333
"@alicloud/console-toolkit-shared-utils": "^1.2.30",

‎packages/plugin-browser-hint/src/index.ts

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,19 @@
11
import { PluginAPI, PluginOptions } from '@alicloud/console-toolkit-core';
22

3-
const browserHint = `
4-
<script type="text/javascript">
5-
(function(){
6-
var userAgent = window.navigator.userAgent;
7-
var isIE = userAgent.indexOf("compatible") > -1 && userAgent.indexOf("MSIE") > -1;
3+
// const browserHint = `
4+
// <script type="text/javascript">
5+
// (function(){
6+
// var userAgent = window.navigator.userAgent;
7+
// var isIE = userAgent.indexOf("compatible") > -1 && userAgent.indexOf("MSIE") > -1;
88

9-
if (isIE) {
10-
document.write('<div style="background: #fffbd7;border-bottom: 1px solid #ffde03;color:#262626;padding: 8px;">很抱歉,您当前使用的浏览器无法获得最佳体验,建议使用 Chrome、Firefox 或 Safari 浏览器登录阿里云控制台继续浏览。</div>');
11-
}
12-
})();
13-
</script>
14-
`;
9+
// if (isIE) {
10+
// document.write('<div style="background: #fffbd7;border-bottom: 1px solid #ffde03;color:#262626;padding: 8px;">很抱歉,您当前使用的浏览器无法获得最佳体验,建议使用 Chrome、Firefox 或 Safari 浏览器登录阿里云控制台继续浏览。</div>');
11+
// }
12+
// })();
13+
// </script>
14+
// `;
15+
16+
const browserHint = '<meta data-type="oneconsole.browser_compatibility" />';
1517

1618
export default (api: PluginAPI, options: PluginOptions) => {
1719
api.dispatchSync('addHtmlPrescript', browserHint);

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /