Commit Graph

386 Commits

Author SHA1 Message Date
Alexander Cerutti
07eb6f5cce Added a bit of space: let's make the code breathe 2023-04-03 21:18:49 +02:00
Alexander Cerutti
9d6dd8c984 Merge pull request #139 from Songkeys/fix-pass-field-types
fix: complete pass field types for typescript
2023-04-03 21:18:13 +02:00
Songkeys
a43d6e55d0 chore: rename for consistency 2023-04-04 00:00:49 +08:00
Songkeys
1dec7d5a6b fix: complete pass field types for typescript 2023-04-03 23:51:31 +08:00
Songkeys
e986fda63b fix: transitType should be read when type is boardingPass (#137) 2023-04-03 23:38:36 +08:00
Jacob Burenstam
ff44540860 Set Semantic.wifiAccess as array type 2023-03-24 16:46:06 +01:00
Alexander Cerutti
ab70e61f81 Changed auxiliaryFields getter return type 2022-11-11 23:54:50 +01:00
Alexander Cerutti
68c9b1588e Added fieldSchema property to FieldsArray 2022-11-09 19:31:44 +01:00
Alexander Cerutti
e4fc8feda8 Added FieldWithRow interface and Joi Schema 2022-11-09 19:30:04 +01:00
Alexander Cerutti
eeb1978728 Made all the regex to get created only once 2022-03-29 22:36:27 +02:00
Alexander Cerutti
fa8b3e18bc Small optimization to PKPass.pack 2022-03-13 00:44:32 +01:00
Alexander Cerutti
951730fb1d Optimized localize null-translations loop 2022-03-13 00:19:50 +01:00
Alexander Cerutti
1212f4b32b Optimized localizationEntries loop 2022-03-13 00:16:53 +01:00
Alexander Cerutti
153ad08885 Improved PKPass.pack to reduce the amount of iterations that gets done 2022-03-12 19:47:06 +01:00
Alexander Cerutti
0b75b98c4a Improved fields warn expression 2022-02-22 00:07:15 +01:00
Alexander Cerutti
27511806a8 Added falsy fields to be automatically excluded with warn being emitted 2022-02-22 00:04:07 +01:00
Frederick Cai
16177dfa49 Fixed FieldsArray.push to preserve the order of input items 2022-02-22 09:09:36 +13:00
Alexander Cerutti
1f79b0d74f Improved comment and formatting for latest fix 2022-02-07 20:54:58 +01:00
billytrend
c32394b4d0 Check for Joi.binary (#100) 2022-02-07 20:46:03 +01:00
Alexander Cerutti
a15dc29290 Added explicit Buffer import declarations 2022-02-07 01:18:06 +01:00
Alexander Cerutti
d0b0f8537f Added path normalization on Windows, along with some tests 2021-12-28 01:05:14 +01:00
Alexander Cerutti
2923eb4d66 Changed quotes and applied change to PKPass.from (which uses internals-like to read model) 2021-12-27 19:34:00 +01:00
tpot
728748d6d5 Fix invalid path for build on windows 2021-12-27 15:44:17 +01:00
Alexander Cerutti
e1ea69df78 Renamed type setter parameter 2021-12-25 12:08:18 +01:00
Alexander Cerutti
cf8a467266 Applied changes to solve several issues about typescript strict mode 2021-12-23 19:46:29 +01:00
Alexander Cerutti
e35d8bede3 Improved type 2021-11-14 00:57:28 +01:00
Alexander Cerutti
a723c152be Made PKPass.from Template to accept optional certificates 2021-11-14 00:51:07 +01:00
Alexander Cerutti
252b9e5cb0 Changed constructor buffers and certificates types to be optional 2021-11-14 00:50:12 +01:00
Alexander Cerutti
5651ce69a5 Added constructor check on certificates to avoid an error if a pass is created using PKPass.from, without specifying the certificates 2021-11-14 00:47:37 +01:00
Alexander Cerutti
964be0802c Added constructor check for buffers 2021-11-14 00:42:14 +01:00
Alexander Cerutti
a0cdc218dd Added languages getter 2021-10-31 20:54:31 +01:00
Alexander Cerutti
56cd96bced FieldsArray: merged assertUnfrozen check with registerWithValidation in splice 2021-10-26 00:13:14 +02:00
Alexander Cerutti
eabee97d89 Removed unused validation function isValid 2021-10-25 01:14:32 +02:00
Alexander Cerutti
e31918d942 Refactored FieldsArray to add overrides for shift and unshift and to share code between methods 2021-10-25 01:00:51 +02:00
Alexander Cerutti
505520813a FieldsArray: fixed splice method to check incoming items and register their keys in pool; 2021-10-24 16:29:41 +02:00
Alexander Cerutti
7c9716c589 Added OverridablePassProps to exported types 2021-10-24 15:39:35 +02:00
Alexander Cerutti
3c706ddbb6 Changed messages format export from default to non-default 2021-10-23 19:09:38 +02:00
Alexander Cerutti
03643834f1 Removed fieldKeysPoolSymbol based on instance to create one when FieldsArray are created. This also solves a keys reset problem when fields gets created from scratch 2021-10-23 18:40:22 +02:00
Alexander Cerutti
bf2f72b14d Removed optional chaining from transitType getter to make it crash if boardingPass does not exist 2021-10-23 00:41:22 +02:00
Alexander Cerutti
53b0c8e1fd Fixed comment 2021-10-23 00:33:27 +02:00
Alexander Cerutti
0ed75ac047 FIxed Bundle test and changed bundle closed message 2021-10-23 00:28:30 +02:00
Alexander Cerutti
86d09b9509 Added checks in PKPass methods to prevent changing contents if pass is frozen 2021-10-23 00:27:27 +02:00
Alexander Cerutti
3b69446873 Changed implementation of FieldsArray to accept passInstance instead of pool, to check frozen instance 2021-10-22 22:37:51 +02:00
Alexander Cerutti
e0c6d61c30 Changed props getter to clone recursively instead of freezing 2021-10-20 21:28:01 +02:00
Alexander Cerutti
1735a3824a Changed logic for formatVersion parsing and defaulting 2021-10-20 00:08:38 +02:00
Alexander Cerutti
757630834d Updated signature content generation method to not use deprecated method createBuffer 2021-10-19 22:37:52 +02:00
Alexander Cerutti
91bee95bfe Fixed localization files reading path out issue 2021-10-19 00:18:11 +02:00
Alexander Cerutti
3290cb1d3f Added formatVersion to pass.json schemas to keep it 2021-10-18 23:54:48 +02:00
Alexander Cerutti
12a6781c14 Fixed Bundle methods calling javascript confusion: Bundle.getAsStream was calling this.getAsBuffer, but this was PKPass instance 2021-10-18 23:54:24 +02:00
Alexander Cerutti
0f72b4dda8 Fixed signature creation dumb copy-paste error 2021-10-18 23:19:36 +02:00