change tl subtick
This commit is contained in:
parent
687749f431
commit
4969f2d7e0
@ -257,7 +257,7 @@ export const Timeline: React.FC<Props> = React.memo(({
|
||||
24625.670894409748,
|
||||
4964.7447283082365,
|
||||
],
|
||||
initialZoomLevel: 4964.7447283082365,
|
||||
initialZoomLevel: 24625.670894409748,
|
||||
onDateChange: async (date: Date) => {
|
||||
const datestr = formatInTimeZone(date, 'UTC', 'yyyyMMddHHmmss')
|
||||
const url_base = process.env.NEXT_PUBLIC_GRAPHQL_BACKEND_URL?.replace('/graphql', '') || 'http://localhost:3050'
|
||||
|
||||
@ -74,7 +74,7 @@ interface TimelineConfig {
|
||||
/** 初始中心时间(时间戳,默认当前时间) */
|
||||
initialCenterTime?: number;
|
||||
/** 初始显示范围(毫秒,默认1小时) */
|
||||
initialTimeRange?: number;
|
||||
initialTimeRange?: number | null;
|
||||
/** Initial Zoom Level */
|
||||
initialZoomLevel?: number | null;
|
||||
/** 缩放模式 */
|
||||
@ -455,7 +455,7 @@ class ScaleManager {
|
||||
{
|
||||
level: TimeFormatLevel.HalfHour,
|
||||
majorInterval: 30 * 60 * 1000, // 30分钟
|
||||
minorTicks: 3, // 每10分钟一个次刻度
|
||||
minorTicks: 4, // 每10分钟一个次刻度
|
||||
minPixelDistance: 50,
|
||||
maxPixelDistance: 120,
|
||||
formatter: (date: Date) => ({
|
||||
@ -937,7 +937,7 @@ class RealTimeTimeline {
|
||||
|
||||
const defaultConfig: Required<TimelineConfig> = {
|
||||
initialCenterTime: Date.now(),
|
||||
initialTimeRange: 60 * 60 * 1000, // 1小时
|
||||
initialTimeRange: null, // 1小时
|
||||
initialZoomLevel: null,
|
||||
zoomMode: ZoomMode.MousePosition,
|
||||
zoomSensitivity: 0.001,
|
||||
|
||||
Loading…
Reference in New Issue
Block a user