fork of hey-api/openapi-ts because I need some additional things
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge pull request #2192 from Daschi1/patch-1

authored by

Lubos and committed by
GitHub
fcb77c96 eb4fb3b1

+20 -15
+5
.changeset/odd-yaks-love.md
··· 1 + --- 2 + "@hey-api/openapi-ts": patch 3 + --- 4 + 5 + fix(valibot): use `isoTimestamp` instead of `isoDateTime` for date-time format
+1 -1
packages/openapi-ts-tests/test/__snapshots__/2.0.x/plugins/valibot/default/valibot.gen.ts
··· 365 365 key: v.pipe(v.string(), v.maxLength(64), v.regex(/^[a-zA-Z0-9_]*$/)), 366 366 name: v.pipe(v.string(), v.maxLength(255)), 367 367 enabled: v.optional(v.pipe(v.boolean(), v.readonly())), 368 - modified: v.optional(v.pipe(v.pipe(v.string(), v.isoDateTime()), v.readonly())), 368 + modified: v.optional(v.pipe(v.pipe(v.string(), v.isoTimestamp()), v.readonly())), 369 369 id: v.optional(v.pipe(v.string(), v.regex(/^\d{2}-\d{3}-\d{4}$/))), 370 370 text: v.optional(v.pipe(v.string(), v.regex(/^\w+$/))), 371 371 patternWithSingleQuotes: v.optional(v.pipe(v.string(), v.regex(/^[a-zA-Z0-9']*$/))),
+6 -6
packages/openapi-ts-tests/test/__snapshots__/3.0.x/plugins/valibot/default/valibot.gen.ts
··· 691 691 key: v.pipe(v.string(), v.maxLength(64), v.regex(/^[a-zA-Z0-9_]*$/)), 692 692 name: v.pipe(v.string(), v.maxLength(255)), 693 693 enabled: v.optional(v.pipe(v.boolean(), v.readonly())), 694 - modified: v.optional(v.pipe(v.pipe(v.string(), v.isoDateTime()), v.readonly())), 694 + modified: v.optional(v.pipe(v.pipe(v.string(), v.isoTimestamp()), v.readonly())), 695 695 id: v.optional(v.pipe(v.string(), v.regex(/^\d{2}-\d{3}-\d{4}$/))), 696 696 text: v.optional(v.pipe(v.string(), v.regex(/^\w+$/))), 697 697 patternWithSingleQuotes: v.optional(v.pipe(v.string(), v.regex(/^[a-zA-Z0-9']*$/))), ··· 701 701 702 702 export const vFile = v.object({ 703 703 id: v.optional(v.pipe(v.pipe(v.string(), v.minLength(1)), v.readonly())), 704 - updated_at: v.optional(v.pipe(v.pipe(v.string(), v.isoDateTime()), v.readonly())), 705 - created_at: v.optional(v.pipe(v.pipe(v.string(), v.isoDateTime()), v.readonly())), 704 + updated_at: v.optional(v.pipe(v.pipe(v.string(), v.isoTimestamp()), v.readonly())), 705 + created_at: v.optional(v.pipe(v.pipe(v.string(), v.isoTimestamp()), v.readonly())), 706 706 mime: v.pipe(v.string(), v.minLength(1), v.maxLength(24)), 707 707 file: v.optional(v.pipe(v.pipe(v.string(), v.url()), v.readonly())) 708 708 }); ··· 816 816 ]) 817 817 }), 818 818 v.object({ 819 - content: v.pipe(v.string(), v.isoDateTime()), 819 + content: v.pipe(v.string(), v.isoTimestamp()), 820 820 foo: v.picklist([ 821 821 'Quux' 822 822 ]) 823 823 }), 824 824 v.object({ 825 825 content: v.tuple([ 826 - v.pipe(v.string(), v.isoDateTime()), 827 - v.pipe(v.string(), v.isoDateTime()) 826 + v.pipe(v.string(), v.isoTimestamp()), 827 + v.pipe(v.string(), v.isoTimestamp()) 828 828 ]), 829 829 foo: v.picklist([ 830 830 'Corge'
+5 -5
packages/openapi-ts-tests/test/__snapshots__/3.1.x/plugins/valibot/default/valibot.gen.ts
··· 686 686 key: v.pipe(v.string(), v.maxLength(64), v.regex(/^[a-zA-Z0-9_]*$/)), 687 687 name: v.pipe(v.string(), v.maxLength(255)), 688 688 enabled: v.optional(v.pipe(v.boolean(), v.readonly())), 689 - modified: v.optional(v.pipe(v.pipe(v.string(), v.isoDateTime()), v.readonly())), 689 + modified: v.optional(v.pipe(v.pipe(v.string(), v.isoTimestamp()), v.readonly())), 690 690 id: v.optional(v.pipe(v.string(), v.regex(/^\d{2}-\d{3}-\d{4}$/))), 691 691 text: v.optional(v.pipe(v.string(), v.regex(/^\w+$/))), 692 692 patternWithSingleQuotes: v.optional(v.pipe(v.string(), v.regex(/^[a-zA-Z0-9']*$/))), ··· 696 696 697 697 export const vFile = v.object({ 698 698 id: v.optional(v.pipe(v.pipe(v.string(), v.minLength(1)), v.readonly())), 699 - updated_at: v.optional(v.pipe(v.pipe(v.string(), v.isoDateTime()), v.readonly())), 700 - created_at: v.optional(v.pipe(v.pipe(v.string(), v.isoDateTime()), v.readonly())), 699 + updated_at: v.optional(v.pipe(v.pipe(v.string(), v.isoTimestamp()), v.readonly())), 700 + created_at: v.optional(v.pipe(v.pipe(v.string(), v.isoTimestamp()), v.readonly())), 701 701 mime: v.pipe(v.string(), v.minLength(1), v.maxLength(24)), 702 702 file: v.optional(v.pipe(v.pipe(v.string(), v.url()), v.readonly())) 703 703 }); ··· 807 807 ]) 808 808 }), 809 809 v.object({ 810 - content: v.pipe(v.string(), v.isoDateTime()), 810 + content: v.pipe(v.string(), v.isoTimestamp()), 811 811 foo: v.picklist([ 812 812 'Quux' 813 813 ]) 814 814 }), 815 815 v.object({ 816 816 content: v.tuple([ 817 - v.pipe(v.string(), v.isoDateTime()), 817 + v.pipe(v.string(), v.isoTimestamp()), 818 818 v.string() 819 819 ]), 820 820 foo: v.picklist([
+1 -1
packages/openapi-ts-tests/test/__snapshots__/3.1.x/validators-metadata/valibot.gen.ts
··· 54 54 55 55 export const vPatchFooParameterQux = v.pipe(v.string(), v.isoDate()); 56 56 57 - export const vPatchFooParameterQuux = v.pipe(v.string(), v.isoDateTime()); 57 + export const vPatchFooParameterQuux = v.pipe(v.string(), v.isoTimestamp()); 58 58 59 59 export const vPostFooData = vFoo3;
+1 -1
packages/openapi-ts-tests/test/__snapshots__/3.1.x/validators/valibot.gen.ts
··· 54 54 55 55 export const vPatchFooParameterQux = v.pipe(v.string(), v.isoDate()); 56 56 57 - export const vPatchFooParameterQuux = v.pipe(v.string(), v.isoDateTime()); 57 + export const vPatchFooParameterQuux = v.pipe(v.string(), v.isoTimestamp()); 58 58 59 59 export const vPostFooData = vFoo3;
+1 -1
packages/openapi-ts/src/plugins/valibot/plugin.ts
··· 542 542 compiler.callExpression({ 543 543 functionName: compiler.propertyAccessExpression({ 544 544 expression: identifiers.v, 545 - name: identifiers.actions.isoDateTime, 545 + name: identifiers.actions.isoTimestamp, 546 546 }), 547 547 }), 548 548 );