Javascript 在ChartJS中设置第二个轴的样式

Javascript 在ChartJS中设置第二个轴的样式,javascript,chart.js,Javascript,Chart.js,在使用多轴时,是否可能以某种方式更改ChartJS中记号的样式?以下是我目前拥有的: 以下是我试图实现的目标: 基本上我想让第二个轴的记号一直延伸到第一个轴。有什么建议吗 以下是我的两个x轴代码: xAxes: [ { id: 'x-axis-1', display: custom.xAxes.display, gridLines: { display: custom.xAxes.gridLi

在使用多轴时,是否可能以某种方式更改ChartJS中记号的样式?以下是我目前拥有的:

以下是我试图实现的目标:

基本上我想让第二个轴的记号一直延伸到第一个轴。有什么建议吗

以下是我的两个x轴代码:

xAxes: [
        {
          id: 'x-axis-1',
          display: custom.xAxes.display,
          gridLines: {
            display: custom.xAxes.gridLines.display,
          },
          type: 'time',
          time: {
            unit: this.getTime(),
            displayFormats: timeDisplayFormats,
          },
          stacked: this.stacked,
          ticks: {
            display: custom.xAxes.ticks.display,
            fontFamily: "Rubik",
            fontColor: '#65686D',
            source: this.xTicksSource,
            maxTicksLimit: 12,
          },
          offset: this.type.find(type => type.type === 'bar'),
        },
        {
          id: 'x-axis-2',
          display: custom.xAxes.display,
          gridLines: {
            drawOnChartArea: false,
            drawBorder: false,
          },
          type: 'time',
          time: {
            unit: 'year',
            displayFormats: timeDisplayFormats,
          },
          stacked: this.stacked,
          ticks: {
            display: custom.xAxes.ticks.display,
            fontFamily: "Rubik",
            fontColor: '#65686D',
            source: this.xTicksSource,
            maxTicksLimit: 12,
          },
          offset: this.type.find(type => type.type === 'bar'),
        },
      ],

有可能从您那里得到一些样本数据吗?这将有助于创建小提琴/代码笔