- ${this._imageUrl ? imageElement : '
'}
-
+ ${this._URL ? imageElement : '
'}
`;
const labelDocument = new DOMParser().parseFromString(htmlString, 'text/html');
@@ -31,12 +30,30 @@ const customImageOverlay = (center, imageUrl) => {
this._div.append(label);
const eventHandler = (event) => {
- event.stopPropagation();
event.preventDefault();
+ this._callback && this._callback(event, [{ _id: this._id }]);
};
if (Utils.isDesktop()) {
- this._div.addEventListener('click', eventHandler);
+ let clickTimeout;
+ this._div.addEventListener('click', (event) => {
+ if (clickTimeout) {
+ clearTimeout(clickTimeout);
+ clickTimeout = null;
+ return;
+ }
+ clickTimeout = setTimeout(() => {
+ eventHandler(event);
+ clickTimeout = null;
+ }, 300);
+ });
+ this._div.addEventListener('dblclick', (e) => {
+ e.preventDefault();
+ if (clickTimeout) {
+ clearTimeout(clickTimeout);
+ clickTimeout = null;
+ }
+ });
} else {
this._div.addEventListener('touchend', eventHandler);
}
@@ -51,7 +68,7 @@ const customImageOverlay = (center, imageUrl) => {
}
getImageUrl() {
- return imageUrl || '';
+ return image.src || '';
}
getPosition() {
@@ -63,7 +80,7 @@ const customImageOverlay = (center, imageUrl) => {
}
}
- return new ImageOverlay(center, imageUrl);
+ return new ImageOverlay(center, image, callback);
};
export default customImageOverlay;
diff --git a/frontend/src/metadata/views/map/map-view/overlay/index.js b/frontend/src/metadata/views/map/map-view/overlay/index.js
new file mode 100644
index 00000000000..21f2d71fa90
--- /dev/null
+++ b/frontend/src/metadata/views/map/map-view/overlay/index.js
@@ -0,0 +1,7 @@
+import customAvatarOverlay from './custom-avatar-overlay';
+import customImageOverlay from './custom-image-overlay';
+
+export {
+ customAvatarOverlay,
+ customImageOverlay
+};
diff --git a/frontend/src/metadata/views/table/utils/grid-utils.js b/frontend/src/metadata/views/table/utils/grid-utils.js
index a835e80223b..3e0d4d9857f 100644
--- a/frontend/src/metadata/views/table/utils/grid-utils.js
+++ b/frontend/src/metadata/views/table/utils/grid-utils.js
@@ -2,8 +2,7 @@ import dayjs from 'dayjs';
import { getCellValueByColumn, getFileNameFromRecord, getRecordIdFromRecord, isCellValueChanged } from '../../../utils/cell';
import { getColumnByIndex, getColumnOriginName } from '../../../utils/column';
import { CellType, NOT_SUPPORT_DRAG_COPY_COLUMN_TYPES, PRIVATE_COLUMN_KEY, TRANSFER_TYPES,
- REG_NUMBER_DIGIT, REG_STRING_NUMBER_PARTS, COLUMN_RATE_MAX_NUMBER,
- PASTE_SOURCE,
+ REG_NUMBER_DIGIT, REG_STRING_NUMBER_PARTS, RATE_MAX_NUMBER, PASTE_SOURCE,
} from '../../../constants';
import { getGroupRecordByIndex } from './group-metrics';
import { convertCellValue } from './convert-utils';
@@ -594,7 +593,7 @@ class GridUtils {
}
_getRatingLeastSquares(numberList, data) {
- const { rate_max_number = COLUMN_RATE_MAX_NUMBER[4].name } = data || {};
+ const { rate_max_number = RATE_MAX_NUMBER[4].name } = data || {};
let slope;
let intercept;
let xAverage;
diff --git a/frontend/src/pages/lib-content-view/lib-content-view.js b/frontend/src/pages/lib-content-view/lib-content-view.js
index f79bf5744cf..bfb212641da 100644
--- a/frontend/src/pages/lib-content-view/lib-content-view.js
+++ b/frontend/src/pages/lib-content-view/lib-content-view.js
@@ -2150,6 +2150,7 @@ class LibContentView extends React.Component {
};
updatePath = (path) => {
+ if (this.state.path === path) return;
this.setState({ path });
};
diff --git a/frontend/src/utils/map-utils.js b/frontend/src/utils/map-utils.js
index 1b68b04acd6..dfa09822257 100644
--- a/frontend/src/utils/map-utils.js
+++ b/frontend/src/utils/map-utils.js
@@ -1,6 +1,8 @@
import { MAP_TYPE } from '../constants';
import { mediaUrl } from './constants';
+const STATIC_RESOURCE_VERSION = 0.1;
+
export const initMapInfo = ({ baiduMapKey, googleMapKey, mineMapKey }) => {
if (baiduMapKey) return { type: MAP_TYPE.B_MAP, key: baiduMapKey };
if (googleMapKey) return { type: MAP_TYPE.G_MAP, key: googleMapKey };
@@ -30,8 +32,8 @@ export const loadMapSource = (type, key, callback) => {
export default function loadBMap(ak) {
return new Promise((resolve, reject) => {
asyncLoadBaiduJs(ak)
- .then(() => asyncLoadJs(`${mediaUrl}/js/map/text-icon-overlay.js`))
- .then(() => asyncLoadJs(`${mediaUrl}/js/map/marker-clusterer.js`))
+ .then(() => asyncLoadJs(`${mediaUrl}/js/map/text-icon-overlay.js?v=${STATIC_RESOURCE_VERSION}`))
+ .then(() => asyncLoadJs(`${mediaUrl}/js/map/marker-cluster.js?v=${STATIC_RESOURCE_VERSION}`))
.then(() => resolve(true))
.catch((err) => reject(err));
});
@@ -39,16 +41,16 @@ export default function loadBMap(ak) {
export function asyncLoadBaiduJs(ak) {
return new Promise((resolve, reject) => {
- if (typeof window.BMap !== 'undefined') {
- resolve(window.BMap);
+ if (typeof window.BMapGL !== 'undefined') {
+ resolve(window.BMapGL);
return;
}
window.renderMap = function () {
- resolve(window.BMap);
+ resolve(window.BMapGL);
};
let script = document.createElement('script');
script.type = 'text/javascript';
- script.src = `https://api.map.baidu.com/api?v=3.0&ak=${ak}&callback=renderMap`;
+ script.src = `https://api.map.baidu.com/api?type=webgl&v=1.0&ak=${ak}&callback=renderMap`;
script.onerror = reject;
document.body.appendChild(script);
});
diff --git a/media/css/sf_font3/iconfont.css b/media/css/sf_font3/iconfont.css
index def6c7fe635..b6650f591a4 100644
--- a/media/css/sf_font3/iconfont.css
+++ b/media/css/sf_font3/iconfont.css
@@ -1,11 +1,11 @@
@font-face {
font-family: "sf3-font"; /* Project id 1230969 */
- src: url('./iconfont.eot?t=1733301127109'); /* IE9 */
- src: url('./iconfont.eot?t=1733301127109#iefix') format('embedded-opentype'), /* IE6-IE8 */
- url('./iconfont.woff2?t=1733301127109') format('woff2'),
- url('./iconfont.woff?t=1733301127109') format('woff'),
- url('./iconfont.ttf?t=1733301127109') format('truetype'),
- url('./iconfont.svg?t=1733301127109#sf3-font') format('svg');
+ src: url('./iconfont.eot?t=1736476800596'); /* IE9 */
+ src: url('./iconfont.eot?t=1736476800596#iefix') format('embedded-opentype'), /* IE6-IE8 */
+ url('./iconfont.woff2?t=1736476800596') format('woff2'),
+ url('./iconfont.woff?t=1736476800596') format('woff'),
+ url('./iconfont.ttf?t=1736476800596') format('truetype'),
+ url('./iconfont.svg?t=1736476800596#sf3-font') format('svg');
}
.sf3-font {
@@ -16,6 +16,30 @@
-moz-osx-font-smoothing: grayscale;
}
+.sf3-font-zoom-out:before {
+ content: "\e630";
+}
+
+.sf3-font-current-location:before {
+ content: "\e62e";
+}
+
+.sf3-font-zoom-in:before {
+ content: "\e62f";
+}
+
+.sf3-font-ai:before {
+ content: "\e854";
+}
+
+.sf3-font-time:before {
+ content: "\e852";
+}
+
+.sf3-font-description:before {
+ content: "\e853";
+}
+
.sf3-font-hi:before {
content: "\e603";
}
@@ -24,10 +48,6 @@
content: "\e851";
}
-.sf3-font-current-location:before {
- content: "\e850";
-}
-
.sf3-font-ai_generated:before {
content: "\e84f";
}
diff --git a/media/css/sf_font3/iconfont.eot b/media/css/sf_font3/iconfont.eot
index 4bb9fed7ba7..bfefade4d69 100644
Binary files a/media/css/sf_font3/iconfont.eot and b/media/css/sf_font3/iconfont.eot differ
diff --git a/media/css/sf_font3/iconfont.svg b/media/css/sf_font3/iconfont.svg
index d40bdac5381..e3a48dd6bf4 100644
--- a/media/css/sf_font3/iconfont.svg
+++ b/media/css/sf_font3/iconfont.svg
@@ -14,12 +14,22 @@
/>