@dmdata/telegram-json-types 1.1.18 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +26 -21
- package/dist/build.js +1 -0
- package/dist/jschema/earthquake-counts_1.0.0.json +1 -1
- package/dist/jschema/earthquake-explanation_1.0.0.json +1 -1
- package/dist/jschema/earthquake-hypocenter-update_1.0.0.json +1 -1
- package/dist/jschema/earthquake-information_1.0.0.json +1 -1
- package/dist/jschema/earthquake-information_1.1.0.json +1 -1
- package/dist/jschema/earthquake-nankai_1.0.0.json +1 -1
- package/dist/jschema/eew-information_1.0.0.json +1 -1
- package/dist/jschema/forecast-2week-temperature_1.0.0.json +1 -1
- package/dist/jschema/forecast-prefecture_1.0.0.json +1 -1
- package/dist/jschema/forecast-season_1.0.0.json +1 -1
- package/dist/jschema/forecast-warning-possibility_1.0.0.json +1 -1
- package/dist/jschema/forecast-warning-possibility_1.1.0.json +1 -0
- package/dist/jschema/forecast-weathermap_1.0.0.json +1 -1
- package/dist/jschema/tsunami-information_1.0.0.json +1 -1
- package/dist/jschema/tsunami-information_1.1.0.json +1 -1
- package/dist/jschema/volcano-information_1.0.0.json +1 -1
- package/dist/jschema/weather-commentary_1.0.0.json +1 -0
- package/dist/jschema/weather-early_1.0.0.json +1 -1
- package/dist/jschema/weather-impact-society_1.0.0.json +1 -1
- package/dist/jschema/weather-impact-society_1.0.1.json +1 -1
- package/dist/jschema/weather-information_1.0.0.json +1 -1
- package/dist/jschema/weather-landslide_1.0.0.json +1 -1
- package/dist/jschema/weather-river-flood_1.0.0.json +1 -1
- package/dist/jschema/weather-tornado_1.0.0.json +1 -1
- package/dist/jschema/weather-typhoon_1.0.0.json +1 -1
- package/dist/jschema/weather-warning-timeseries_1.0.0.json +1 -0
- package/dist/jschema/weather-warning_1.0.0.json +1 -1
- package/dist/jschema/weather-warning_1.1.0.json +1 -0
- package/package.json +5 -5
- package/test/sample-schema-check.test.ts +3 -1
- package/tsconfig.json +3 -1
- package/types/component/index.d.ts +17 -14
- package/types/component/util.d.ts +20 -0
- package/types/index.d.ts +8 -0
- package/types/schema/earthquake-information/1.1.0.d.ts +2 -2
- package/types/schema/forecast-prefecture/1.0.0.d.ts +12 -1
- package/types/schema/forecast-warning-possibility/1.0.0.d.ts +14 -8
- package/types/schema/forecast-warning-possibility/1.1.0.d.ts +129 -0
- package/types/schema/forecast-warning-possibility/index.d.ts +9 -7
- package/types/schema/weather-commentary/1.0.0.d.ts +984 -0
- package/types/schema/weather-commentary/index.d.ts +7 -0
- package/types/schema/weather-early/1.0.0.d.ts +1 -0
- package/types/schema/weather-impact-society/1.0.0.d.ts +1 -0
- package/types/schema/weather-impact-society/1.0.1.d.ts +1 -0
- package/types/schema/weather-tornado/1.0.0.d.ts +4 -0
- package/types/schema/weather-typhoon/1.0.0.d.ts +14 -2
- package/types/schema/weather-warning/1.0.0.d.ts +1 -0
- package/types/schema/weather-warning/1.1.0.d.ts +469 -0
- package/types/schema/weather-warning/index.d.ts +9 -7
- package/types/schema/weather-warning-timeseries/1.0.0.d.ts +385 -0
- package/types/schema/weather-warning-timeseries/index.d.ts +7 -0
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
import { TelegramJSONMain } from '../../main';
|
|
2
|
+
import { Components } from '../../component';
|
|
3
|
+
|
|
4
|
+
export namespace ForecastWarningPossibility {
|
|
5
|
+
export interface Schema {
|
|
6
|
+
type: 'forecast-warning-possibility';
|
|
7
|
+
version: '1.1.0';
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export interface TimeSeriesTimeDefine {
|
|
11
|
+
timeId: string;
|
|
12
|
+
dateTime: string;
|
|
13
|
+
duration: string;
|
|
14
|
+
name: string;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export type PossibilityRankType = `${'大雨' | '土砂災害' | '雪' | '風(風雪)' | '波' | '潮位'}の警報級の可能性`;
|
|
18
|
+
|
|
19
|
+
export type PossibilityRankOfWarning<Type extends PossibilityRankType> = {
|
|
20
|
+
refId: string;
|
|
21
|
+
type: Type;
|
|
22
|
+
value: '中' | '高' | 'なし';
|
|
23
|
+
condition?: never;
|
|
24
|
+
} | {
|
|
25
|
+
refId: string;
|
|
26
|
+
type: Type;
|
|
27
|
+
value: null;
|
|
28
|
+
condition: '値なし';
|
|
29
|
+
};
|
|
30
|
+
|
|
31
|
+
export interface Text {
|
|
32
|
+
text: string;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export interface TimeSeriesPropertyPossibilityRankOfWarning<Type extends PossibilityRankType> {
|
|
36
|
+
type: Type;
|
|
37
|
+
possibilityRankOfWarnings: PossibilityRankOfWarning<Type>[];
|
|
38
|
+
texts?: [Text];
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
export type TimeSeriesPropertyRain = TimeSeriesPropertyPossibilityRankOfWarning<'大雨の警報級の可能性'>;
|
|
42
|
+
export type TimeSeriesPropertyLandslide = TimeSeriesPropertyPossibilityRankOfWarning<'土砂災害の警報級の可能性'>;
|
|
43
|
+
export type TimeSeriesPropertySnow = TimeSeriesPropertyPossibilityRankOfWarning<'雪の警報級の可能性'>;
|
|
44
|
+
export type TimeSeriesPropertyWind = TimeSeriesPropertyPossibilityRankOfWarning<'風(風雪)の警報級の可能性'>;
|
|
45
|
+
export type TimeSeriesPropertyWave = TimeSeriesPropertyPossibilityRankOfWarning<'波の警報級の可能性'>;
|
|
46
|
+
export type TimeSeriesPropertyTide = TimeSeriesPropertyPossibilityRankOfWarning<'潮位の警報級の可能性'>;
|
|
47
|
+
|
|
48
|
+
export type TimeSeriesProperty =
|
|
49
|
+
TimeSeriesPropertyRain |
|
|
50
|
+
TimeSeriesPropertyLandslide |
|
|
51
|
+
TimeSeriesPropertySnow |
|
|
52
|
+
TimeSeriesPropertyWind |
|
|
53
|
+
TimeSeriesPropertyWave |
|
|
54
|
+
TimeSeriesPropertyTide;
|
|
55
|
+
|
|
56
|
+
export type TimeSeriesPropertiesRain = [TimeSeriesPropertyRain];
|
|
57
|
+
export type TimeSeriesPropertiesLandslide = [TimeSeriesPropertyLandslide];
|
|
58
|
+
export type TimeSeriesPropertiesSnow = [TimeSeriesPropertySnow];
|
|
59
|
+
export type TimeSeriesPropertiesWind = [TimeSeriesPropertyWind];
|
|
60
|
+
export type TimeSeriesPropertiesWave = [TimeSeriesPropertyWave];
|
|
61
|
+
export type TimeSeriesPropertiesTide = [TimeSeriesPropertyTide];
|
|
62
|
+
|
|
63
|
+
export type TimeSeriesKindProperties =
|
|
64
|
+
TimeSeriesPropertiesRain |
|
|
65
|
+
TimeSeriesPropertiesLandslide |
|
|
66
|
+
TimeSeriesPropertiesSnow |
|
|
67
|
+
TimeSeriesPropertiesWind |
|
|
68
|
+
TimeSeriesPropertiesWave |
|
|
69
|
+
TimeSeriesPropertiesTide;
|
|
70
|
+
|
|
71
|
+
export interface TimeSeriesKind<P extends [TimeSeriesProperty]> {
|
|
72
|
+
properties: P;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export type TimeSeriesKinds = [
|
|
76
|
+
TimeSeriesKind<TimeSeriesPropertiesRain>,
|
|
77
|
+
TimeSeriesKind<TimeSeriesPropertiesLandslide>,
|
|
78
|
+
TimeSeriesKind<TimeSeriesPropertiesSnow>,
|
|
79
|
+
TimeSeriesKind<TimeSeriesPropertiesWind>,
|
|
80
|
+
TimeSeriesKind<TimeSeriesPropertiesWave>,
|
|
81
|
+
TimeSeriesKind<TimeSeriesPropertiesTide>
|
|
82
|
+
] | [
|
|
83
|
+
TimeSeriesKind<TimeSeriesPropertiesRain>,
|
|
84
|
+
TimeSeriesKind<TimeSeriesPropertiesLandslide>,
|
|
85
|
+
TimeSeriesKind<TimeSeriesPropertiesSnow>,
|
|
86
|
+
TimeSeriesKind<TimeSeriesPropertiesWind>,
|
|
87
|
+
TimeSeriesKind<TimeSeriesPropertiesWave> |
|
|
88
|
+
TimeSeriesKind<TimeSeriesPropertiesTide>
|
|
89
|
+
] | [
|
|
90
|
+
TimeSeriesKind<TimeSeriesPropertiesRain>,
|
|
91
|
+
TimeSeriesKind<TimeSeriesPropertiesLandslide>,
|
|
92
|
+
TimeSeriesKind<TimeSeriesPropertiesSnow>,
|
|
93
|
+
TimeSeriesKind<TimeSeriesPropertiesWind>
|
|
94
|
+
];
|
|
95
|
+
|
|
96
|
+
export interface TimeSeriesItem extends Components.CodeName {
|
|
97
|
+
kinds: TimeSeriesKinds;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
export interface TimeSeries {
|
|
101
|
+
timeDefines: TimeSeriesTimeDefine[];
|
|
102
|
+
items: TimeSeriesItem[];
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
export interface Region {
|
|
106
|
+
type: '区域予報';
|
|
107
|
+
timeSeries: [TimeSeries];
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
export interface PublicBody {
|
|
111
|
+
region: Region;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
export interface Public extends TelegramJSONMain {
|
|
115
|
+
_schema: Schema;
|
|
116
|
+
type: '早期注意情報(明後日まで)' | string;
|
|
117
|
+
title: string;
|
|
118
|
+
infoType: '発表' | '訂正' | '遅延';
|
|
119
|
+
targetDateTimeDubious: never;
|
|
120
|
+
targetDuration: string;
|
|
121
|
+
validDateTime: never;
|
|
122
|
+
eventId: null;
|
|
123
|
+
serialNo: null;
|
|
124
|
+
infoKind: string;
|
|
125
|
+
body: PublicBody;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
export type Main = Public;
|
|
129
|
+
}
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import { ForecastWarningPossibility as
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
1
|
+
import { ForecastWarningPossibility as v1_1_0 } from './1.1.0';
|
|
2
|
+
import { ForecastWarningPossibility as v1_0_0 } from './1.0.0';
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
export {
|
|
6
|
+
v1_1_0 as Latest,
|
|
7
|
+
v1_1_0,
|
|
8
|
+
v1_0_0
|
|
9
|
+
};
|