@rpcbase/ui 0.248.0 → 0.250.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/dist/index105.js +36 -36
- package/dist/index117.js +6 -6
- package/dist/index120.js +10 -10
- package/dist/index122.js +2 -2
- package/dist/index123.js +3 -3
- package/dist/index124.js +1 -1
- package/dist/index126.js +2 -2
- package/dist/index128.js +2 -2
- package/dist/index167.js +3 -3
- package/dist/index172.js +9 -9
- package/dist/index175.js +1 -1
- package/dist/index176.js +4 -4
- package/dist/index178.js +1 -1
- package/dist/index182.js +2 -2
- package/dist/index184.js +5 -5
- package/dist/index185.js +13 -13
- package/dist/index186.js +1 -1
- package/dist/index188.js +6 -6
- package/dist/index189.js +1 -1
- package/dist/index192.js +2 -2
- package/dist/index193.js +6 -6
- package/dist/index194.js +20 -59
- package/dist/index194.js.map +1 -1
- package/dist/index195.js +66 -8
- package/dist/index195.js.map +1 -1
- package/dist/index196.js +6 -87
- package/dist/index196.js.map +1 -1
- package/dist/index197.js +5 -19
- package/dist/index197.js.map +1 -1
- package/dist/index198.js +11 -16
- package/dist/index198.js.map +1 -1
- package/dist/index199.js +3 -5
- package/dist/index199.js.map +1 -1
- package/dist/index200.js +49 -4
- package/dist/index200.js.map +1 -1
- package/dist/index201.js +4 -7
- package/dist/index201.js.map +1 -1
- package/dist/index202.js +29 -4
- package/dist/index202.js.map +1 -1
- package/dist/index203.js +16 -6
- package/dist/index203.js.map +1 -1
- package/dist/index204.js +5 -16
- package/dist/index204.js.map +1 -1
- package/dist/index205.js +21 -4
- package/dist/index205.js.map +1 -1
- package/dist/index206.js +53 -4
- package/dist/index206.js.map +1 -1
- package/dist/index207.js +20 -12
- package/dist/index207.js.map +1 -1
- package/dist/index208.js +41 -9
- package/dist/index208.js.map +1 -1
- package/dist/index209.js +39 -13
- package/dist/index209.js.map +1 -1
- package/dist/index210.js +46 -14
- package/dist/index210.js.map +1 -1
- package/dist/index211.js +20 -4
- package/dist/index211.js.map +1 -1
- package/dist/index212.js +70 -5
- package/dist/index212.js.map +1 -1
- package/dist/index213.js +17 -6
- package/dist/index213.js.map +1 -1
- package/dist/index214.js +3 -5
- package/dist/index214.js.map +1 -1
- package/dist/index215.js +11 -54
- package/dist/index215.js.map +1 -1
- package/dist/index216.js +13 -8
- package/dist/index216.js.map +1 -1
- package/dist/index217.js +18 -4
- package/dist/index217.js.map +1 -1
- package/dist/index218.js +36 -4
- package/dist/index218.js.map +1 -1
- package/dist/index219.js +239 -8
- package/dist/index219.js.map +1 -1
- package/dist/index220.js +252 -4
- package/dist/index220.js.map +1 -1
- package/dist/index221.js +68 -4
- package/dist/index221.js.map +1 -1
- package/dist/index222.js +99 -3
- package/dist/index222.js.map +1 -1
- package/dist/index223.js +83 -10
- package/dist/index223.js.map +1 -1
- package/dist/index224.js +3 -9
- package/dist/index224.js.map +1 -1
- package/dist/index225.js +29 -9
- package/dist/index225.js.map +1 -1
- package/dist/index226.js +16 -10
- package/dist/index226.js.map +1 -1
- package/dist/index227.js +35 -11
- package/dist/index227.js.map +1 -1
- package/dist/index228.js +17 -9
- package/dist/index228.js.map +1 -1
- package/dist/index229.js +3 -6
- package/dist/index229.js.map +1 -1
- package/dist/index230.js +26 -5
- package/dist/index230.js.map +1 -1
- package/dist/index231.js +28 -4
- package/dist/index231.js.map +1 -1
- package/dist/index232.js +4 -6
- package/dist/index232.js.map +1 -1
- package/dist/index233.js +78 -6
- package/dist/index233.js.map +1 -1
- package/dist/index234.js +272 -5
- package/dist/index234.js.map +1 -1
- package/dist/index235.js +10 -15
- package/dist/index235.js.map +1 -1
- package/dist/index236.js +10 -7
- package/dist/index236.js.map +1 -1
- package/dist/index237.js +25 -10
- package/dist/index237.js.map +1 -1
- package/dist/index238.js +16 -10
- package/dist/index238.js.map +1 -1
- package/dist/index239.js +125 -21
- package/dist/index239.js.map +1 -1
- package/dist/index240.js +5 -8
- package/dist/index240.js.map +1 -1
- package/dist/index241.js +65 -9
- package/dist/index241.js.map +1 -1
- package/dist/index242.js +14 -10
- package/dist/index242.js.map +1 -1
- package/dist/index243.js +7 -4
- package/dist/index243.js.map +1 -1
- package/dist/index244.js +5 -5
- package/dist/index244.js.map +1 -1
- package/dist/index245.js +3 -16
- package/dist/index245.js.map +1 -1
- package/dist/index246.js +10 -9
- package/dist/index246.js.map +1 -1
- package/dist/index247.js +7 -18
- package/dist/index247.js.map +1 -1
- package/dist/index248.js +132 -19
- package/dist/index248.js.map +1 -1
- package/dist/index249.js +397 -10
- package/dist/index249.js.map +1 -1
- package/dist/index250.js +5 -30
- package/dist/index250.js.map +1 -1
- package/dist/index251.js +52 -12
- package/dist/index251.js.map +1 -1
- package/dist/index252.js +11 -25
- package/dist/index252.js.map +1 -1
- package/dist/index253.js +27 -5
- package/dist/index253.js.map +1 -1
- package/dist/index254.js +12 -20
- package/dist/index254.js.map +1 -1
- package/dist/index255.js +57 -65
- package/dist/index255.js.map +1 -1
- package/dist/index256.js +8 -6
- package/dist/index256.js.map +1 -1
- package/dist/index257.js +87 -5
- package/dist/index257.js.map +1 -1
- package/dist/index258.js +19 -11
- package/dist/index258.js.map +1 -1
- package/dist/index259.js +16 -3
- package/dist/index259.js.map +1 -1
- package/dist/index260.js +4 -49
- package/dist/index260.js.map +1 -1
- package/dist/index261.js +6 -4
- package/dist/index261.js.map +1 -1
- package/dist/index262.js +6 -29
- package/dist/index262.js.map +1 -1
- package/dist/index263.js +4 -16
- package/dist/index263.js.map +1 -1
- package/dist/index264.js +6 -5
- package/dist/index264.js.map +1 -1
- package/dist/index265.js +16 -21
- package/dist/index265.js.map +1 -1
- package/dist/index266.js +4 -53
- package/dist/index266.js.map +1 -1
- package/dist/index267.js +4 -20
- package/dist/index267.js.map +1 -1
- package/dist/index268.js +12 -41
- package/dist/index268.js.map +1 -1
- package/dist/index269.js +9 -39
- package/dist/index269.js.map +1 -1
- package/dist/index270.js +14 -46
- package/dist/index270.js.map +1 -1
- package/dist/index271.js +13 -20
- package/dist/index271.js.map +1 -1
- package/dist/index272.js +4 -70
- package/dist/index272.js.map +1 -1
- package/dist/index273.js +5 -17
- package/dist/index273.js.map +1 -1
- package/dist/index274.js +6 -3
- package/dist/index274.js.map +1 -1
- package/dist/index275.js +5 -11
- package/dist/index275.js.map +1 -1
- package/dist/index276.js +53 -12
- package/dist/index276.js.map +1 -1
- package/dist/index277.js +8 -18
- package/dist/index277.js.map +1 -1
- package/dist/index278.js +4 -36
- package/dist/index278.js.map +1 -1
- package/dist/index279.js +4 -239
- package/dist/index279.js.map +1 -1
- package/dist/index280.js +8 -252
- package/dist/index280.js.map +1 -1
- package/dist/index281.js +4 -68
- package/dist/index281.js.map +1 -1
- package/dist/index282.js +4 -99
- package/dist/index282.js.map +1 -1
- package/dist/index283.js +3 -83
- package/dist/index283.js.map +1 -1
- package/dist/index284.js +10 -3
- package/dist/index284.js.map +1 -1
- package/dist/index285.js +9 -29
- package/dist/index285.js.map +1 -1
- package/dist/index286.js +9 -16
- package/dist/index286.js.map +1 -1
- package/dist/index287.js +11 -35
- package/dist/index287.js.map +1 -1
- package/dist/index288.js +10 -17
- package/dist/index288.js.map +1 -1
- package/dist/index289.js +9 -3
- package/dist/index289.js.map +1 -1
- package/dist/index290.js +6 -26
- package/dist/index290.js.map +1 -1
- package/dist/index291.js +5 -28
- package/dist/index291.js.map +1 -1
- package/dist/index292.js +5 -4
- package/dist/index292.js.map +1 -1
- package/dist/index293.js +5 -78
- package/dist/index293.js.map +1 -1
- package/dist/index294.js +6 -272
- package/dist/index294.js.map +1 -1
- package/dist/index295.js +5 -11
- package/dist/index295.js.map +1 -1
- package/dist/index296.js +16 -10
- package/dist/index296.js.map +1 -1
- package/dist/index297.js +7 -25
- package/dist/index297.js.map +1 -1
- package/dist/index298.js +10 -16
- package/dist/index298.js.map +1 -1
- package/dist/index299.js +9 -124
- package/dist/index299.js.map +1 -1
- package/dist/index300.js +21 -5
- package/dist/index300.js.map +1 -1
- package/dist/index301.js +8 -65
- package/dist/index301.js.map +1 -1
- package/dist/index302.js +10 -14
- package/dist/index302.js.map +1 -1
- package/dist/index303.js +9 -7
- package/dist/index303.js.map +1 -1
- package/dist/index304.js +4 -5
- package/dist/index304.js.map +1 -1
- package/dist/index305.js +5 -3
- package/dist/index305.js.map +1 -1
- package/dist/index306.js +16 -10
- package/dist/index306.js.map +1 -1
- package/dist/index307.js +9 -7
- package/dist/index307.js.map +1 -1
- package/dist/index308.js +17 -132
- package/dist/index308.js.map +1 -1
- package/dist/index309.js +18 -397
- package/dist/index309.js.map +1 -1
- package/dist/index310.js +13 -5
- package/dist/index310.js.map +1 -1
- package/dist/index311.js +29 -52
- package/dist/index311.js.map +1 -1
- package/dist/index312.js +12 -11
- package/dist/index312.js.map +1 -1
- package/dist/index313.js +25 -27
- package/dist/index313.js.map +1 -1
- package/dist/index314.js +5 -11
- package/dist/index314.js.map +1 -1
- package/dist/index317.js +1 -1
- package/dist/index318.js +1 -1
- package/dist/index321.js +2 -2
- package/dist/index322.js +1 -1
- package/dist/index325.js +1 -1
- package/dist/index330.js +3 -135
- package/dist/index330.js.map +1 -1
- package/dist/index331.js +134 -16
- package/dist/index331.js.map +1 -1
- package/dist/index332.js +17 -15
- package/dist/index332.js.map +1 -1
- package/dist/index333.js +15 -3
- package/dist/index333.js.map +1 -1
- package/dist/index334.js +2 -2
- package/dist/index338.js +24 -8
- package/dist/index338.js.map +1 -1
- package/dist/index339.js +28 -11
- package/dist/index339.js.map +1 -1
- package/dist/index340.js +15 -7
- package/dist/index340.js.map +1 -1
- package/dist/index341.js +8 -13
- package/dist/index341.js.map +1 -1
- package/dist/index342.js +11 -3
- package/dist/index342.js.map +1 -1
- package/dist/index343.js +8 -3
- package/dist/index343.js.map +1 -1
- package/dist/index344.js +12 -16
- package/dist/index344.js.map +1 -1
- package/dist/index345.js +3 -24
- package/dist/index345.js.map +1 -1
- package/dist/index346.js +3 -28
- package/dist/index346.js.map +1 -1
- package/dist/index347.js +50 -15
- package/dist/index347.js.map +1 -1
- package/dist/index348.js +5 -51
- package/dist/index348.js.map +1 -1
- package/dist/index349.js +4 -4
- package/dist/index351.js +17 -5
- package/dist/index351.js.map +1 -1
- package/dist/index357.js +1 -1
- package/dist/index358.js +5 -5
- package/dist/index359.js +1 -1
- package/dist/index362.js +4 -5
- package/dist/index362.js.map +1 -1
- package/dist/index363.js +6 -18
- package/dist/index363.js.map +1 -1
- package/dist/index364.js +3 -13
- package/dist/index364.js.map +1 -1
- package/dist/index365.js +12 -4
- package/dist/index365.js.map +1 -1
- package/dist/index366.js +19 -10
- package/dist/index366.js.map +1 -1
- package/dist/index367.js +45 -6
- package/dist/index367.js.map +1 -1
- package/dist/index368.js +18 -3
- package/dist/index368.js.map +1 -1
- package/dist/index369.js +5 -21
- package/dist/index369.js.map +1 -1
- package/dist/index370.js +200 -44
- package/dist/index370.js.map +1 -1
- package/dist/index371.js +73 -17
- package/dist/index371.js.map +1 -1
- package/dist/index372.js +124 -5
- package/dist/index372.js.map +1 -1
- package/dist/index373.js +4 -200
- package/dist/index373.js.map +1 -1
- package/dist/index374.js +18 -74
- package/dist/index374.js.map +1 -1
- package/dist/index375.js +12 -123
- package/dist/index375.js.map +1 -1
- package/dist/index379.js +4 -4
- package/dist/index380.js +3 -3
- package/dist/index382.js +1 -1
- package/dist/index384.js +1 -1
- package/dist/index385.js +2 -2
- package/dist/index388.js +2 -2
- package/dist/index389.js +2 -2
- package/dist/index392.js +3 -5
- package/dist/index392.js.map +1 -1
- package/dist/index393.js +3 -5
- package/dist/index393.js.map +1 -1
- package/dist/index394.js +5 -4
- package/dist/index394.js.map +1 -1
- package/dist/index395.js +4 -15
- package/dist/index395.js.map +1 -1
- package/dist/index396.js +4 -9
- package/dist/index396.js.map +1 -1
- package/dist/index397.js +15 -5
- package/dist/index397.js.map +1 -1
- package/dist/index398.js +8 -4
- package/dist/index398.js.map +1 -1
- package/dist/index399.js +5 -545
- package/dist/index399.js.map +1 -1
- package/dist/index400.js +5 -47
- package/dist/index400.js.map +1 -1
- package/dist/index401.js +543 -15
- package/dist/index401.js.map +1 -1
- package/dist/index402.js +47 -6
- package/dist/index402.js.map +1 -1
- package/dist/index403.js +17 -7
- package/dist/index403.js.map +1 -1
- package/dist/index404.js +5 -6
- package/dist/index404.js.map +1 -1
- package/dist/index405.js +7 -7
- package/dist/index405.js.map +1 -1
- package/dist/index406.js +6 -11
- package/dist/index406.js.map +1 -1
- package/dist/index407.js +7 -8
- package/dist/index407.js.map +1 -1
- package/dist/index408.js +11 -12
- package/dist/index408.js.map +1 -1
- package/dist/index409.js +9 -3
- package/dist/index409.js.map +1 -1
- package/dist/index410.js +13 -3
- package/dist/index410.js.map +1 -1
- package/dist/index411.js +3 -15
- package/dist/index411.js.map +1 -1
- package/dist/index412.js +15 -3
- package/dist/index412.js.map +1 -1
- package/dist/index413.js +1 -1
- package/dist/index414.js +7 -4
- package/dist/index414.js.map +1 -1
- package/dist/index415.js +2 -56
- package/dist/index415.js.map +1 -1
- package/dist/index416.js +43 -67
- package/dist/index416.js.map +1 -1
- package/dist/index417.js +56 -31
- package/dist/index417.js.map +1 -1
- package/dist/index418.js +8 -9
- package/dist/index418.js.map +1 -1
- package/dist/index419.js +2 -153
- package/dist/index419.js.map +1 -1
- package/dist/index420.js +54 -107
- package/dist/index420.js.map +1 -1
- package/dist/index421.js +55 -7
- package/dist/index421.js.map +1 -1
- package/dist/index422.js +33 -2
- package/dist/index422.js.map +1 -1
- package/dist/index423.js +4 -43
- package/dist/index423.js.map +1 -1
- package/dist/index424.js +55 -55
- package/dist/index424.js.map +1 -1
- package/dist/index425.js +68 -8
- package/dist/index425.js.map +1 -1
- package/dist/index426.js +31 -2
- package/dist/index426.js.map +1 -1
- package/dist/index427.js +9 -55
- package/dist/index427.js.map +1 -1
- package/dist/index428.js +152 -55
- package/dist/index428.js.map +1 -1
- package/dist/index429.js +107 -32
- package/dist/index429.js.map +1 -1
- package/dist/index430.js +2 -16
- package/dist/index430.js.map +1 -1
- package/dist/index431.js +2 -29
- package/dist/index431.js.map +1 -1
- package/dist/index432.js +2 -13
- package/dist/index432.js.map +1 -1
- package/dist/index433.js +2 -7
- package/dist/index433.js.map +1 -1
- package/dist/index434.js +16 -2
- package/dist/index434.js.map +1 -1
- package/dist/index435.js +29 -2
- package/dist/index435.js.map +1 -1
- package/dist/index436.js +13 -2
- package/dist/index436.js.map +1 -1
- package/dist/index437.js +7 -2
- package/dist/index437.js.map +1 -1
- package/dist/index49.js +30 -30
- package/dist/index50.js +21 -21
- package/dist/index51.js +1 -1
- package/dist/index52.js +8 -8
- package/dist/index53.js +2 -2
- package/dist/index55.js +16 -16
- package/dist/index56.js +4 -4
- package/dist/index57.js +3 -3
- package/dist/index58.js +7 -7
- package/dist/index59.js +4 -4
- package/dist/index60.js +12 -12
- package/dist/index61.js +2 -2
- package/dist/index62.js +2 -2
- package/package.json +1 -1
package/dist/index339.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index339.js","sources":["../../../node_modules
|
|
1
|
+
{"version":3,"file":"index339.js","sources":["../../../node_modules/libphonenumber-js/es6/helpers/extractNationalNumberFromPossiblyIncompleteNumber.js"],"sourcesContent":["/**\r\n * Strips any national prefix (such as 0, 1) present in a\r\n * (possibly incomplete) number provided.\r\n * \"Carrier codes\" are only used in Colombia and Brazil,\r\n * and only when dialing within those countries from a mobile phone to a fixed line number.\r\n * Sometimes it won't actually strip national prefix\r\n * and will instead prepend some digits to the `number`:\r\n * for example, when number `2345678` is passed with `VI` country selected,\r\n * it will return `{ number: \"3402345678\" }`, because `340` area code is prepended.\r\n * @param {string} number — National number digits.\r\n * @param {object} metadata — Metadata with country selected.\r\n * @return {object} `{ nationalNumber: string, nationalPrefix: string? carrierCode: string? }`. Even if a national prefix was extracted, it's not necessarily present in the returned object, so don't rely on its presence in the returned object in order to find out whether a national prefix has been extracted or not.\r\n */\nexport default function extractNationalNumberFromPossiblyIncompleteNumber(number, metadata) {\n if (number && metadata.numberingPlan.nationalPrefixForParsing()) {\n // See METADATA.md for the description of\n // `national_prefix_for_parsing` and `national_prefix_transform_rule`.\n // Attempt to parse the first digits as a national prefix.\n var prefixPattern = new RegExp('^(?:' + metadata.numberingPlan.nationalPrefixForParsing() + ')');\n var prefixMatch = prefixPattern.exec(number);\n if (prefixMatch) {\n var nationalNumber;\n var carrierCode;\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/blob/master/METADATA.md#national_prefix_for_parsing--national_prefix_transform_rule\n // If a `national_prefix_for_parsing` has any \"capturing groups\"\n // then it means that the national (significant) number is equal to\n // those \"capturing groups\" transformed via `national_prefix_transform_rule`,\n // and nothing could be said about the actual national prefix:\n // what is it and was it even there.\n // If a `national_prefix_for_parsing` doesn't have any \"capturing groups\",\n // then everything it matches is a national prefix.\n // To determine whether `national_prefix_for_parsing` matched any\n // \"capturing groups\", the value of the result of calling `.exec()`\n // is looked at, and if it has non-undefined values where there're\n // \"capturing groups\" in the regular expression, then it means\n // that \"capturing groups\" have been matched.\n // It's not possible to tell whether there'll be any \"capturing gropus\"\n // before the matching process, because a `national_prefix_for_parsing`\n // could exhibit both behaviors.\n var capturedGroupsCount = prefixMatch.length - 1;\n var hasCapturedGroups = capturedGroupsCount > 0 && prefixMatch[capturedGroupsCount];\n if (metadata.nationalPrefixTransformRule() && hasCapturedGroups) {\n nationalNumber = number.replace(prefixPattern, metadata.nationalPrefixTransformRule());\n // If there's more than one captured group,\n // then carrier code is the second one.\n if (capturedGroupsCount > 1) {\n carrierCode = prefixMatch[1];\n }\n }\n // If there're no \"capturing groups\",\n // or if there're \"capturing groups\" but no\n // `national_prefix_transform_rule`,\n // then just strip the national prefix from the number,\n // and possibly a carrier code.\n // Seems like there could be more.\n else {\n // `prefixBeforeNationalNumber` is the whole substring matched by\n // the `national_prefix_for_parsing` regular expression.\n // There seem to be no guarantees that it's just a national prefix.\n // For example, if there's a carrier code, it's gonna be a\n // part of `prefixBeforeNationalNumber` too.\n var prefixBeforeNationalNumber = prefixMatch[0];\n nationalNumber = number.slice(prefixBeforeNationalNumber.length);\n // If there's at least one captured group,\n // then carrier code is the first one.\n if (hasCapturedGroups) {\n carrierCode = prefixMatch[1];\n }\n }\n // Tries to guess whether a national prefix was present in the input.\n // This is not something copy-pasted from Google's library:\n // they don't seem to have an equivalent for that.\n // So this isn't an \"officially approved\" way of doing something like that.\n // But since there seems no other existing method, this library uses it.\n var nationalPrefix;\n if (hasCapturedGroups) {\n var possiblePositionOfTheFirstCapturedGroup = number.indexOf(prefixMatch[1]);\n var possibleNationalPrefix = number.slice(0, possiblePositionOfTheFirstCapturedGroup);\n // Example: an Argentinian (AR) phone number `0111523456789`.\n // `prefixMatch[0]` is `01115`, and `$1` is `11`,\n // and the rest of the phone number is `23456789`.\n // The national number is transformed via `9$1` to `91123456789`.\n // National prefix `0` is detected being present at the start.\n // if (possibleNationalPrefix.indexOf(metadata.numberingPlan.nationalPrefix()) === 0) {\n if (possibleNationalPrefix === metadata.numberingPlan.nationalPrefix()) {\n nationalPrefix = metadata.numberingPlan.nationalPrefix();\n }\n } else {\n nationalPrefix = prefixMatch[0];\n }\n return {\n nationalNumber: nationalNumber,\n nationalPrefix: nationalPrefix,\n carrierCode: carrierCode\n };\n }\n }\n return {\n nationalNumber: number\n };\n}\n//# sourceMappingURL=extractNationalNumberFromPossiblyIncompleteNumber.js.map"],"names":["extractNationalNumberFromPossiblyIncompleteNumber","number","metadata","prefixPattern","prefixMatch","nationalNumber","carrierCode","capturedGroupsCount","hasCapturedGroups","prefixBeforeNationalNumber","nationalPrefix","possiblePositionOfTheFirstCapturedGroup","possibleNationalPrefix"],"mappings":"AAae,SAASA,EAAkDC,GAAQC,GAAU;AAC1F,MAAID,KAAUC,EAAS,cAAc,yBAAwB,GAAI;AAI/D,QAAIC,IAAgB,IAAI,OAAO,SAASD,EAAS,cAAc,yBAAwB,IAAK,GAAG,GAC3FE,IAAcD,EAAc,KAAKF,CAAM;AAC3C,QAAIG,GAAa;AACf,UAAIC,GACAC,GAiBAC,IAAsBH,EAAY,SAAS,GAC3CI,IAAoBD,IAAsB,KAAKH,EAAYG,CAAmB;AAClF,UAAIL,EAAS,4BAA2B,KAAMM;AAC5C,QAAAH,IAAiBJ,EAAO,QAAQE,GAAeD,EAAS,4BAA2B,CAAE,GAGjFK,IAAsB,MACxBD,IAAcF,EAAY,CAAC;AAAA,WAS1B;AAMH,YAAIK,IAA6BL,EAAY,CAAC;AAC9C,QAAAC,IAAiBJ,EAAO,MAAMQ,EAA2B,MAAM,GAG3DD,MACFF,IAAcF,EAAY,CAAC;AAAA,MAE/B;AAMA,UAAIM;AACJ,UAAIF,GAAmB;AACrB,YAAIG,IAA0CV,EAAO,QAAQG,EAAY,CAAC,CAAC,GACvEQ,IAAyBX,EAAO,MAAM,GAAGU,CAAuC;AAOpF,QAAIC,MAA2BV,EAAS,cAAc,eAAc,MAClEQ,IAAiBR,EAAS,cAAc,eAAc;AAAA,MAE1D;AACE,QAAAQ,IAAiBN,EAAY,CAAC;AAEhC,aAAO;AAAA,QACL,gBAAgBC;AAAA,QAChB,gBAAgBK;AAAA,QAChB,aAAaJ;AAAA,MACrB;AAAA,IACI;AAAA,EACF;AACA,SAAO;AAAA,IACL,gBAAgBL;AAAA,EACpB;AACA;","x_google_ignoreList":[0]}
|
package/dist/index340.js
CHANGED
|
@@ -1,12 +1,20 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
import I from "./index163.js";
|
|
2
|
+
import { VALID_DIGITS as l } from "./index159.js";
|
|
3
|
+
var p = new RegExp("([" + l + "])");
|
|
4
|
+
function c(t, r, f, n) {
|
|
5
|
+
if (r) {
|
|
6
|
+
var a = new I(n);
|
|
7
|
+
a.selectNumberingPlan(r || f);
|
|
8
|
+
var i = new RegExp(a.IDDPrefix());
|
|
9
|
+
if (t.search(i) === 0) {
|
|
10
|
+
t = t.slice(t.match(i)[0].length);
|
|
11
|
+
var e = t.match(p);
|
|
12
|
+
if (!(e && e[1] != null && e[1].length > 0 && e[1] === "0"))
|
|
13
|
+
return t;
|
|
14
|
+
}
|
|
7
15
|
}
|
|
8
16
|
}
|
|
9
17
|
export {
|
|
10
|
-
|
|
18
|
+
c as default
|
|
11
19
|
};
|
|
12
20
|
//# sourceMappingURL=index340.js.map
|
package/dist/index340.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index340.js","sources":["../../../node_modules
|
|
1
|
+
{"version":3,"file":"index340.js","sources":["../../../node_modules/libphonenumber-js/es6/helpers/stripIddPrefix.js"],"sourcesContent":["import Metadata from '../metadata.js';\nimport { VALID_DIGITS } from '../constants.js';\nvar CAPTURING_DIGIT_PATTERN = new RegExp('([' + VALID_DIGITS + '])');\nexport default function stripIddPrefix(number, country, callingCode, metadataJson) {\n if (!country) {\n return;\n }\n\n // Get the IDD prefix pattern.\n var metadata = new Metadata(metadataJson);\n metadata.selectNumberingPlan(country || callingCode);\n var IDDPrefixPattern = new RegExp(metadata.IDDPrefix());\n\n // Check if the number is IDD-prefixed.\n if (number.search(IDDPrefixPattern) !== 0) {\n return;\n }\n\n // Strip IDD prefix.\n number = number.slice(number.match(IDDPrefixPattern)[0].length);\n\n // If there're any digits after an IDD prefix,\n // then those digits are a country calling code.\n // Since no country code starts with a `0`,\n // the code below validates that the next digit (if present) is not `0`.\n var matchedGroups = number.match(CAPTURING_DIGIT_PATTERN);\n if (matchedGroups && matchedGroups[1] != null && matchedGroups[1].length > 0) {\n if (matchedGroups[1] === '0') {\n return;\n }\n }\n return number;\n}\n//# sourceMappingURL=stripIddPrefix.js.map"],"names":["CAPTURING_DIGIT_PATTERN","VALID_DIGITS","stripIddPrefix","number","country","callingCode","metadataJson","metadata","Metadata","IDDPrefixPattern","matchedGroups"],"mappings":";;AAEA,IAAIA,IAA0B,IAAI,OAAO,OAAOC,IAAe,IAAI;AACpD,SAASC,EAAeC,GAAQC,GAASC,GAAaC,GAAc;AACjF,MAAKF,GAKL;AAAA,QAAIG,IAAW,IAAIC,EAASF,CAAY;AACxC,IAAAC,EAAS,oBAAoBH,KAAWC,CAAW;AACnD,QAAII,IAAmB,IAAI,OAAOF,EAAS,UAAS,CAAE;AAGtD,QAAIJ,EAAO,OAAOM,CAAgB,MAAM,GAKxC;AAAA,MAAAN,IAASA,EAAO,MAAMA,EAAO,MAAMM,CAAgB,EAAE,CAAC,EAAE,MAAM;AAM9D,UAAIC,IAAgBP,EAAO,MAAMH,CAAuB;AACxD,UAAI,EAAAU,KAAiBA,EAAc,CAAC,KAAK,QAAQA,EAAc,CAAC,EAAE,SAAS,KACrEA,EAAc,CAAC,MAAM;AAI3B,eAAOP;AAAA;AAAA;AACT;","x_google_ignoreList":[0]}
|
package/dist/index341.js
CHANGED
|
@@ -1,17 +1,12 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
continue;
|
|
9
|
-
}
|
|
10
|
-
e === !0 ? o[`data-${t.toLowerCase()}`] = "" : e && (o[`data-${t.toLowerCase()}`] = e.toString());
|
|
11
|
-
}
|
|
12
|
-
return o;
|
|
1
|
+
import * as n from "react";
|
|
2
|
+
import { isReactVersionAtLeast as o } from "./index348.js";
|
|
3
|
+
function s(t) {
|
|
4
|
+
if (!/* @__PURE__ */ n.isValidElement(t))
|
|
5
|
+
return null;
|
|
6
|
+
const e = t, r = e.props;
|
|
7
|
+
return (o(19) ? r?.ref : e.ref) ?? null;
|
|
13
8
|
}
|
|
14
9
|
export {
|
|
15
|
-
|
|
10
|
+
s as getReactElementRef
|
|
16
11
|
};
|
|
17
12
|
//# sourceMappingURL=index341.js.map
|
package/dist/index341.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index341.js","sources":["../../../node_modules/@base-ui/
|
|
1
|
+
{"version":3,"file":"index341.js","sources":["../../../node_modules/@base-ui/utils/getReactElementRef.mjs"],"sourcesContent":["import * as React from 'react';\nimport { isReactVersionAtLeast } from \"./reactVersion.mjs\";\n\n/**\n * Extracts the `ref` from a React element, handling different React versions.\n */\nexport function getReactElementRef(element) {\n if (! /*#__PURE__*/React.isValidElement(element)) {\n return null;\n }\n const reactElement = element;\n const propsWithRef = reactElement.props;\n return (isReactVersionAtLeast(19) ? propsWithRef?.ref : reactElement.ref) ?? null;\n}"],"names":["getReactElementRef","element","React","reactElement","propsWithRef","isReactVersionAtLeast"],"mappings":";;AAMO,SAASA,EAAmBC,GAAS;AAC1C,MAAI,CAAe,gBAAAC,EAAM,eAAeD,CAAO;AAC7C,WAAO;AAET,QAAME,IAAeF,GACfG,IAAeD,EAAa;AAClC,UAAQE,EAAsB,EAAE,IAAID,GAAc,MAAMD,EAAa,QAAQ;AAC/E;","x_google_ignoreList":[0]}
|
package/dist/index342.js
CHANGED
|
@@ -1,7 +1,15 @@
|
|
|
1
|
-
function
|
|
2
|
-
|
|
1
|
+
function n(e, r) {
|
|
2
|
+
if (e && !r)
|
|
3
|
+
return e;
|
|
4
|
+
if (!e && r)
|
|
5
|
+
return r;
|
|
6
|
+
if (e || r)
|
|
7
|
+
return {
|
|
8
|
+
...e,
|
|
9
|
+
...r
|
|
10
|
+
};
|
|
3
11
|
}
|
|
4
12
|
export {
|
|
5
|
-
|
|
13
|
+
n as mergeObjects
|
|
6
14
|
};
|
|
7
15
|
//# sourceMappingURL=index342.js.map
|
package/dist/index342.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index342.js","sources":["../../../node_modules/@base-ui/
|
|
1
|
+
{"version":3,"file":"index342.js","sources":["../../../node_modules/@base-ui/utils/mergeObjects.mjs"],"sourcesContent":["export function mergeObjects(a, b) {\n if (a && !b) {\n return a;\n }\n if (!a && b) {\n return b;\n }\n if (a || b) {\n return {\n ...a,\n ...b\n };\n }\n return undefined;\n}"],"names":["mergeObjects","a","b"],"mappings":"AAAO,SAASA,EAAaC,GAAGC,GAAG;AACjC,MAAID,KAAK,CAACC;AACR,WAAOD;AAET,MAAI,CAACA,KAAKC;AACR,WAAOA;AAET,MAAID,KAAKC;AACP,WAAO;AAAA,MACL,GAAGD;AAAA,MACH,GAAGC;AAAA,IACT;AAGA;","x_google_ignoreList":[0]}
|
package/dist/index343.js
CHANGED
|
@@ -1,7 +1,12 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
let n;
|
|
2
|
+
process.env.NODE_ENV !== "production" && (n = /* @__PURE__ */ new Set());
|
|
3
|
+
function s(...o) {
|
|
4
|
+
if (process.env.NODE_ENV !== "production") {
|
|
5
|
+
const e = o.join(" ");
|
|
6
|
+
n.has(e) || (n.add(e), console.warn(`Base UI: ${e}`));
|
|
7
|
+
}
|
|
3
8
|
}
|
|
4
9
|
export {
|
|
5
|
-
|
|
10
|
+
s as warn
|
|
6
11
|
};
|
|
7
12
|
//# sourceMappingURL=index343.js.map
|
package/dist/index343.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index343.js","sources":["../../../node_modules/@base-ui/
|
|
1
|
+
{"version":3,"file":"index343.js","sources":["../../../node_modules/@base-ui/utils/warn.mjs"],"sourcesContent":["let set;\nif (process.env.NODE_ENV !== 'production') {\n set = new Set();\n}\nexport function warn(...messages) {\n if (process.env.NODE_ENV !== 'production') {\n const messageKey = messages.join(' ');\n if (!set.has(messageKey)) {\n set.add(messageKey);\n console.warn(`Base UI: ${messageKey}`);\n }\n }\n}"],"names":["set","warn","messages","messageKey"],"mappings":"AAAA,IAAIA;AACA,QAAQ,IAAI,aAAa,iBAC3BA,IAAM,oBAAI,IAAG;AAER,SAASC,KAAQC,GAAU;AAChC,MAAI,QAAQ,IAAI,aAAa,cAAc;AACzC,UAAMC,IAAaD,EAAS,KAAK,GAAG;AACpC,IAAKF,EAAI,IAAIG,CAAU,MACrBH,EAAI,IAAIG,CAAU,GAClB,QAAQ,KAAK,YAAYA,CAAU,EAAE;AAAA,EAEzC;AACF;","x_google_ignoreList":[0]}
|
package/dist/index344.js
CHANGED
|
@@ -1,21 +1,17 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
function I(u, t) {
|
|
12
|
-
if (a !== void 0) {
|
|
13
|
-
const e = a();
|
|
14
|
-
return u ?? (t ? `${t}-${e}` : e);
|
|
1
|
+
function i(r, n) {
|
|
2
|
+
const o = {};
|
|
3
|
+
for (const t in r) {
|
|
4
|
+
const e = r[t];
|
|
5
|
+
if (n?.hasOwnProperty(t)) {
|
|
6
|
+
const s = n[t](e);
|
|
7
|
+
s != null && Object.assign(o, s);
|
|
8
|
+
continue;
|
|
9
|
+
}
|
|
10
|
+
e === !0 ? o[`data-${t.toLowerCase()}`] = "" : e && (o[`data-${t.toLowerCase()}`] = e.toString());
|
|
15
11
|
}
|
|
16
|
-
return
|
|
12
|
+
return o;
|
|
17
13
|
}
|
|
18
14
|
export {
|
|
19
|
-
|
|
15
|
+
i as getStateAttributesProps
|
|
20
16
|
};
|
|
21
17
|
//# sourceMappingURL=index344.js.map
|
package/dist/index344.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index344.js","sources":["../../../node_modules/@base-ui/
|
|
1
|
+
{"version":3,"file":"index344.js","sources":["../../../node_modules/@base-ui/react/internals/getStateAttributesProps.mjs"],"sourcesContent":["export function getStateAttributesProps(state, customMapping) {\n const props = {};\n\n /* eslint-disable-next-line guard-for-in */\n for (const key in state) {\n const value = state[key];\n if (customMapping?.hasOwnProperty(key)) {\n const customProps = customMapping[key](value);\n if (customProps != null) {\n Object.assign(props, customProps);\n }\n continue;\n }\n if (value === true) {\n props[`data-${key.toLowerCase()}`] = '';\n } else if (value) {\n props[`data-${key.toLowerCase()}`] = value.toString();\n }\n }\n return props;\n}"],"names":["getStateAttributesProps","state","customMapping","props","key","value","customProps"],"mappings":"AAAO,SAASA,EAAwBC,GAAOC,GAAe;AAC5D,QAAMC,IAAQ,CAAA;AAGd,aAAWC,KAAOH,GAAO;AACvB,UAAMI,IAAQJ,EAAMG,CAAG;AACvB,QAAIF,GAAe,eAAeE,CAAG,GAAG;AACtC,YAAME,IAAcJ,EAAcE,CAAG,EAAEC,CAAK;AAC5C,MAAIC,KAAe,QACjB,OAAO,OAAOH,GAAOG,CAAW;AAElC;AAAA,IACF;AACA,IAAID,MAAU,KACZF,EAAM,QAAQC,EAAI,YAAW,CAAE,EAAE,IAAI,KAC5BC,MACTF,EAAM,QAAQC,EAAI,YAAW,CAAE,EAAE,IAAIC,EAAM,SAAQ;AAAA,EAEvD;AACA,SAAOF;AACT;","x_google_ignoreList":[0]}
|
package/dist/index345.js
CHANGED
|
@@ -1,28 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
import N from "./index334.js";
|
|
4
|
-
import h from "./index165.js";
|
|
5
|
-
function C(r, i, e, o, l) {
|
|
6
|
-
if (!(i || e || o))
|
|
7
|
-
return {
|
|
8
|
-
number: r
|
|
9
|
-
};
|
|
10
|
-
var t = i || e ? b(i || e, l) : o;
|
|
11
|
-
if (r.indexOf(t) === 0) {
|
|
12
|
-
var n = new v(l);
|
|
13
|
-
n.selectNumberingPlan(i || e || o);
|
|
14
|
-
var m = r.slice(t.length), c = N(m, void 0, n), g = c.nationalNumber, a = N(r, void 0, n), f = a.nationalNumber;
|
|
15
|
-
if (!u(f, n.nationalNumberPattern()) && u(g, n.nationalNumberPattern()) || h(f, void 0, n) === "TOO_LONG")
|
|
16
|
-
return {
|
|
17
|
-
countryCallingCode: t,
|
|
18
|
-
number: m
|
|
19
|
-
};
|
|
20
|
-
}
|
|
21
|
-
return {
|
|
22
|
-
number: r
|
|
23
|
-
};
|
|
1
|
+
function t(n, o) {
|
|
2
|
+
return typeof n == "function" ? n(o) : n;
|
|
24
3
|
}
|
|
25
4
|
export {
|
|
26
|
-
|
|
5
|
+
t as resolveClassName
|
|
27
6
|
};
|
|
28
7
|
//# sourceMappingURL=index345.js.map
|
package/dist/index345.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index345.js","sources":["../../../node_modules
|
|
1
|
+
{"version":3,"file":"index345.js","sources":["../../../node_modules/@base-ui/react/utils/resolveClassName.mjs"],"sourcesContent":["/**\n * If the provided className is a string, it will be returned as is.\n * Otherwise, the function will call the className function with the state as the first argument.\n *\n * @param className\n * @param state\n */\nexport function resolveClassName(className, state) {\n return typeof className === 'function' ? className(state) : className;\n}"],"names":["resolveClassName","className","state"],"mappings":"AAOO,SAASA,EAAiBC,GAAWC,GAAO;AACjD,SAAO,OAAOD,KAAc,aAAaA,EAAUC,CAAK,IAAID;AAC9D;","x_google_ignoreList":[0]}
|
package/dist/index346.js
CHANGED
|
@@ -1,32 +1,7 @@
|
|
|
1
|
-
function
|
|
2
|
-
|
|
3
|
-
var g = new RegExp("^(?:" + i.numberingPlan.nationalPrefixForParsing() + ")"), n = g.exec(l);
|
|
4
|
-
if (n) {
|
|
5
|
-
var r, P, v = n.length - 1, e = v > 0 && n[v];
|
|
6
|
-
if (i.nationalPrefixTransformRule() && e)
|
|
7
|
-
r = l.replace(g, i.nationalPrefixTransformRule()), v > 1 && (P = n[1]);
|
|
8
|
-
else {
|
|
9
|
-
var o = n[0];
|
|
10
|
-
r = l.slice(o.length), e && (P = n[1]);
|
|
11
|
-
}
|
|
12
|
-
var f;
|
|
13
|
-
if (e) {
|
|
14
|
-
var s = l.indexOf(n[1]), a = l.slice(0, s);
|
|
15
|
-
a === i.numberingPlan.nationalPrefix() && (f = i.numberingPlan.nationalPrefix());
|
|
16
|
-
} else
|
|
17
|
-
f = n[0];
|
|
18
|
-
return {
|
|
19
|
-
nationalNumber: r,
|
|
20
|
-
nationalPrefix: f,
|
|
21
|
-
carrierCode: P
|
|
22
|
-
};
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
return {
|
|
26
|
-
nationalNumber: l
|
|
27
|
-
};
|
|
1
|
+
function e(n, o) {
|
|
2
|
+
return typeof n == "function" ? n(o) : n;
|
|
28
3
|
}
|
|
29
4
|
export {
|
|
30
|
-
|
|
5
|
+
e as resolveStyle
|
|
31
6
|
};
|
|
32
7
|
//# sourceMappingURL=index346.js.map
|
package/dist/index346.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index346.js","sources":["../../../node_modules
|
|
1
|
+
{"version":3,"file":"index346.js","sources":["../../../node_modules/@base-ui/react/utils/resolveStyle.mjs"],"sourcesContent":["/**\n * If the provided style is an object, it will be returned as is.\n * Otherwise, the function will call the style function with the state as the first argument.\n *\n * @param style\n * @param state\n */\nexport function resolveStyle(style, state) {\n return typeof style === 'function' ? style(state) : style;\n}"],"names":["resolveStyle","style","state"],"mappings":"AAOO,SAASA,EAAaC,GAAOC,GAAO;AACzC,SAAO,OAAOD,KAAU,aAAaA,EAAMC,CAAK,IAAID;AACtD;","x_google_ignoreList":[0]}
|
package/dist/index347.js
CHANGED
|
@@ -1,20 +1,55 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
1
|
+
import * as l from "react-dom";
|
|
2
|
+
import { useAnimationFrame as b } from "./index241.js";
|
|
3
|
+
import { useStableCallback as A } from "./index202.js";
|
|
4
|
+
import { resolveRef as d } from "./index387.js";
|
|
5
|
+
import { TransitionStatusDataAttributes as h } from "./index174.js";
|
|
6
|
+
function y(c, f = !1, m = !0) {
|
|
7
|
+
const o = b();
|
|
8
|
+
return A((s, n = null) => {
|
|
9
|
+
o.cancel();
|
|
10
|
+
const a = d(c);
|
|
11
|
+
if (a == null)
|
|
12
|
+
return;
|
|
13
|
+
const e = a, u = () => {
|
|
14
|
+
l.flushSync(s);
|
|
15
|
+
};
|
|
16
|
+
if (typeof e.getAnimations != "function" || globalThis.BASE_UI_ANIMATIONS_DISABLED) {
|
|
17
|
+
s();
|
|
18
|
+
return;
|
|
14
19
|
}
|
|
15
|
-
|
|
20
|
+
function i() {
|
|
21
|
+
Promise.all(e.getAnimations().map((t) => t.finished)).then(() => {
|
|
22
|
+
n?.aborted || u();
|
|
23
|
+
}).catch(() => {
|
|
24
|
+
if (m) {
|
|
25
|
+
n?.aborted || u();
|
|
26
|
+
return;
|
|
27
|
+
}
|
|
28
|
+
const t = e.getAnimations();
|
|
29
|
+
!n?.aborted && t.length > 0 && t.some((r) => r.pending || r.playState !== "finished") && i();
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
if (f) {
|
|
33
|
+
const t = h.startingStyle;
|
|
34
|
+
if (!e.hasAttribute(t)) {
|
|
35
|
+
o.request(i);
|
|
36
|
+
return;
|
|
37
|
+
}
|
|
38
|
+
const r = new MutationObserver(() => {
|
|
39
|
+
e.hasAttribute(t) || (r.disconnect(), i());
|
|
40
|
+
});
|
|
41
|
+
r.observe(e, {
|
|
42
|
+
attributes: !0,
|
|
43
|
+
attributeFilter: [t]
|
|
44
|
+
}), n?.addEventListener("abort", () => r.disconnect(), {
|
|
45
|
+
once: !0
|
|
46
|
+
});
|
|
47
|
+
return;
|
|
48
|
+
}
|
|
49
|
+
o.request(i);
|
|
50
|
+
});
|
|
16
51
|
}
|
|
17
52
|
export {
|
|
18
|
-
|
|
53
|
+
y as useAnimationsFinished
|
|
19
54
|
};
|
|
20
55
|
//# sourceMappingURL=index347.js.map
|
package/dist/index347.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index347.js","sources":["../../../node_modules
|
|
1
|
+
{"version":3,"file":"index347.js","sources":["../../../node_modules/@base-ui/react/internals/useAnimationsFinished.mjs"],"sourcesContent":["'use client';\n\nimport * as ReactDOM from 'react-dom';\nimport { useAnimationFrame } from '@base-ui/utils/useAnimationFrame';\nimport { useStableCallback } from '@base-ui/utils/useStableCallback';\nimport { resolveRef } from \"../utils/resolveRef.mjs\";\nimport { TransitionStatusDataAttributes } from \"./stateAttributesMapping.mjs\";\n\n/**\n * Executes a function once all animations have finished on the provided element.\n * @param elementOrRef - The element to watch for animations.\n * @param waitForStartingStyleRemoved - Whether to wait for [data-starting-style] to be removed before checking for animations.\n * @param treatAbortedAsFinished - Whether to treat aborted animations as finished. If `false`, and there are aborted animations,\n * the function will check again if any new animations have started and wait for them to finish.\n * @returns A function that takes a callback to execute once all animations have finished, and an optional AbortSignal to abort the callback\n */\nexport function useAnimationsFinished(elementOrRef, waitForStartingStyleRemoved = false, treatAbortedAsFinished = true) {\n const frame = useAnimationFrame();\n return useStableCallback((fnToExecute,\n /**\n * An optional [AbortSignal](https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal) that\n * can be used to abort `fnToExecute` before all the animations have finished.\n * @default null\n */\n signal = null) => {\n frame.cancel();\n const element = resolveRef(elementOrRef);\n if (element == null) {\n return;\n }\n const resolvedElement = element;\n const done = () => {\n // Synchronously flush the unmounting of the component so that the browser doesn't\n // paint: https://github.com/mui/base-ui/issues/979\n ReactDOM.flushSync(fnToExecute);\n };\n if (typeof resolvedElement.getAnimations !== 'function' || globalThis.BASE_UI_ANIMATIONS_DISABLED) {\n fnToExecute();\n return;\n }\n function exec() {\n Promise.all(resolvedElement.getAnimations().map(animation => animation.finished)).then(() => {\n if (!signal?.aborted) {\n done();\n }\n }).catch(() => {\n if (treatAbortedAsFinished) {\n if (!signal?.aborted) {\n done();\n }\n return;\n }\n const currentAnimations = resolvedElement.getAnimations();\n if (!signal?.aborted && currentAnimations.length > 0 && currentAnimations.some(animation => animation.pending || animation.playState !== 'finished')) {\n // Sometimes animations can be aborted because a property they depend on changes while the animation plays.\n // In such cases, we need to re-check if any new animations have started.\n exec();\n }\n });\n }\n if (waitForStartingStyleRemoved) {\n const startingStyleAttribute = TransitionStatusDataAttributes.startingStyle;\n\n // If `[data-starting-style]` isn't present, fall back to waiting one more frame\n // to give \"open\" animations a chance to be registered.\n if (!resolvedElement.hasAttribute(startingStyleAttribute)) {\n frame.request(exec);\n return;\n }\n\n // Wait for `[data-starting-style]` to have been removed.\n const attributeObserver = new MutationObserver(() => {\n if (!resolvedElement.hasAttribute(startingStyleAttribute)) {\n attributeObserver.disconnect();\n exec();\n }\n });\n attributeObserver.observe(resolvedElement, {\n attributes: true,\n attributeFilter: [startingStyleAttribute]\n });\n signal?.addEventListener('abort', () => attributeObserver.disconnect(), {\n once: true\n });\n return;\n }\n frame.request(exec);\n });\n}"],"names":["useAnimationsFinished","elementOrRef","waitForStartingStyleRemoved","treatAbortedAsFinished","frame","useAnimationFrame","useStableCallback","fnToExecute","signal","element","resolveRef","resolvedElement","done","ReactDOM","exec","animation","currentAnimations","startingStyleAttribute","TransitionStatusDataAttributes","attributeObserver"],"mappings":";;;;;AAgBO,SAASA,EAAsBC,GAAcC,IAA8B,IAAOC,IAAyB,IAAM;AACtH,QAAMC,IAAQC,EAAiB;AAC/B,SAAOC,EAAkB,CAACC,GAM1BC,IAAS,SAAS;AAChB,IAAAJ,EAAM,OAAM;AACZ,UAAMK,IAAUC,EAAWT,CAAY;AACvC,QAAIQ,KAAW;AACb;AAEF,UAAME,IAAkBF,GAClBG,IAAO,MAAM;AAGjB,MAAAC,EAAS,UAAUN,CAAW;AAAA,IAChC;AACA,QAAI,OAAOI,EAAgB,iBAAkB,cAAc,WAAW,6BAA6B;AACjG,MAAAJ,EAAW;AACX;AAAA,IACF;AACA,aAASO,IAAO;AACd,cAAQ,IAAIH,EAAgB,gBAAgB,IAAI,CAAAI,MAAaA,EAAU,QAAQ,CAAC,EAAE,KAAK,MAAM;AAC3F,QAAKP,GAAQ,WACXI,EAAI;AAAA,MAER,CAAC,EAAE,MAAM,MAAM;AACb,YAAIT,GAAwB;AAC1B,UAAKK,GAAQ,WACXI,EAAI;AAEN;AAAA,QACF;AACA,cAAMI,IAAoBL,EAAgB,cAAa;AACvD,QAAI,CAACH,GAAQ,WAAWQ,EAAkB,SAAS,KAAKA,EAAkB,KAAK,CAAAD,MAAaA,EAAU,WAAWA,EAAU,cAAc,UAAU,KAGjJD,EAAI;AAAA,MAER,CAAC;AAAA,IACH;AACA,QAAIZ,GAA6B;AAC/B,YAAMe,IAAyBC,EAA+B;AAI9D,UAAI,CAACP,EAAgB,aAAaM,CAAsB,GAAG;AACzD,QAAAb,EAAM,QAAQU,CAAI;AAClB;AAAA,MACF;AAGA,YAAMK,IAAoB,IAAI,iBAAiB,MAAM;AACnD,QAAKR,EAAgB,aAAaM,CAAsB,MACtDE,EAAkB,WAAU,GAC5BL,EAAI;AAAA,MAER,CAAC;AACD,MAAAK,EAAkB,QAAQR,GAAiB;AAAA,QACzC,YAAY;AAAA,QACZ,iBAAiB,CAACM,CAAsB;AAAA,MAChD,CAAO,GACDT,GAAQ,iBAAiB,SAAS,MAAMW,EAAkB,WAAU,GAAI;AAAA,QACtE,MAAM;AAAA,MACd,CAAO;AACD;AAAA,IACF;AACA,IAAAf,EAAM,QAAQU,CAAI;AAAA,EACpB,CAAC;AACH;","x_google_ignoreList":[0]}
|
package/dist/index348.js
CHANGED
|
@@ -1,55 +1,9 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
import { TransitionStatusDataAttributes as h } from "./index174.js";
|
|
6
|
-
function y(c, f = !1, m = !0) {
|
|
7
|
-
const o = b();
|
|
8
|
-
return A((s, n = null) => {
|
|
9
|
-
o.cancel();
|
|
10
|
-
const a = d(c);
|
|
11
|
-
if (a == null)
|
|
12
|
-
return;
|
|
13
|
-
const e = a, u = () => {
|
|
14
|
-
l.flushSync(s);
|
|
15
|
-
};
|
|
16
|
-
if (typeof e.getAnimations != "function" || globalThis.BASE_UI_ANIMATIONS_DISABLED) {
|
|
17
|
-
s();
|
|
18
|
-
return;
|
|
19
|
-
}
|
|
20
|
-
function i() {
|
|
21
|
-
Promise.all(e.getAnimations().map((t) => t.finished)).then(() => {
|
|
22
|
-
n?.aborted || u();
|
|
23
|
-
}).catch(() => {
|
|
24
|
-
if (m) {
|
|
25
|
-
n?.aborted || u();
|
|
26
|
-
return;
|
|
27
|
-
}
|
|
28
|
-
const t = e.getAnimations();
|
|
29
|
-
!n?.aborted && t.length > 0 && t.some((r) => r.pending || r.playState !== "finished") && i();
|
|
30
|
-
});
|
|
31
|
-
}
|
|
32
|
-
if (f) {
|
|
33
|
-
const t = h.startingStyle;
|
|
34
|
-
if (!e.hasAttribute(t)) {
|
|
35
|
-
o.request(i);
|
|
36
|
-
return;
|
|
37
|
-
}
|
|
38
|
-
const r = new MutationObserver(() => {
|
|
39
|
-
e.hasAttribute(t) || (r.disconnect(), i());
|
|
40
|
-
});
|
|
41
|
-
r.observe(e, {
|
|
42
|
-
attributes: !0,
|
|
43
|
-
attributeFilter: [t]
|
|
44
|
-
}), n?.addEventListener("abort", () => r.disconnect(), {
|
|
45
|
-
once: !0
|
|
46
|
-
});
|
|
47
|
-
return;
|
|
48
|
-
}
|
|
49
|
-
o.request(i);
|
|
50
|
-
});
|
|
1
|
+
import * as t from "react";
|
|
2
|
+
const e = parseInt(t.version, 10);
|
|
3
|
+
function o(r) {
|
|
4
|
+
return e >= r;
|
|
51
5
|
}
|
|
52
6
|
export {
|
|
53
|
-
|
|
7
|
+
o as isReactVersionAtLeast
|
|
54
8
|
};
|
|
55
9
|
//# sourceMappingURL=index348.js.map
|
package/dist/index348.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index348.js","sources":["../../../node_modules/@base-ui/
|
|
1
|
+
{"version":3,"file":"index348.js","sources":["../../../node_modules/@base-ui/utils/reactVersion.mjs"],"sourcesContent":["import * as React from 'react';\nconst majorVersion = parseInt(React.version, 10);\nexport function isReactVersionAtLeast(reactVersionToCheck) {\n return majorVersion >= reactVersionToCheck;\n}"],"names":["majorVersion","React","isReactVersionAtLeast","reactVersionToCheck"],"mappings":";AACA,MAAMA,IAAe,SAASC,EAAM,SAAS,EAAE;AACxC,SAASC,EAAsBC,GAAqB;AACzD,SAAOH,KAAgBG;AACzB;","x_google_ignoreList":[0]}
|
package/dist/index349.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import * as r from "react";
|
|
2
|
-
import { useScrollLock as P } from "./
|
|
3
|
-
import { EMPTY_OBJECT as f } from "./
|
|
2
|
+
import { useScrollLock as P } from "./index372.js";
|
|
3
|
+
import { EMPTY_OBJECT as f } from "./index204.js";
|
|
4
4
|
import { createChangeEventDetails as C } from "./index175.js";
|
|
5
5
|
import { usePopupRootSync as S, useImplicitActiveTrigger as k, useOpenStateTransitions as E, usePopupInteractionProps as T } from "./index184.js";
|
|
6
|
-
import { useDismiss as h } from "./
|
|
7
|
-
import { getTarget as w, contains as x } from "./
|
|
6
|
+
import { useDismiss as h } from "./index219.js";
|
|
7
|
+
import { getTarget as w, contains as x } from "./index231.js";
|
|
8
8
|
import { imperativeAction as I } from "./index177.js";
|
|
9
9
|
function L(e) {
|
|
10
10
|
const {
|
package/dist/index351.js
CHANGED
|
@@ -1,9 +1,21 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
import * as n from "react";
|
|
2
|
+
import { SafeReact as f } from "./index353.js";
|
|
3
|
+
let o = 0;
|
|
4
|
+
function l(u, t = "mui") {
|
|
5
|
+
const [e, s] = n.useState(u), c = u || e;
|
|
6
|
+
return n.useEffect(() => {
|
|
7
|
+
e == null && (o += 1, s(`${t}-${o}`));
|
|
8
|
+
}, [e, t]), c;
|
|
9
|
+
}
|
|
10
|
+
const a = f.useId;
|
|
11
|
+
function I(u, t) {
|
|
12
|
+
if (a !== void 0) {
|
|
13
|
+
const e = a();
|
|
14
|
+
return u ?? (t ? `${t}-${e}` : e);
|
|
15
|
+
}
|
|
16
|
+
return l(u, t);
|
|
5
17
|
}
|
|
6
18
|
export {
|
|
7
|
-
|
|
19
|
+
I as useId
|
|
8
20
|
};
|
|
9
21
|
//# sourceMappingURL=index351.js.map
|
package/dist/index351.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index351.js","sources":["../../../node_modules/@base-ui/utils/
|
|
1
|
+
{"version":3,"file":"index351.js","sources":["../../../node_modules/@base-ui/utils/useId.mjs"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { SafeReact } from \"./safeReact.mjs\";\nlet globalId = 0;\n\n// TODO React 17: Remove `useGlobalId` once React 17 support is removed\nfunction useGlobalId(idOverride, prefix = 'mui') {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`${prefix}-${globalId}`);\n }\n }, [defaultId, prefix]);\n return id;\n}\nconst maybeReactUseId = SafeReact.useId;\n\n/**\n *\n * @example <div id={useId()} />\n * @param idOverride\n * @returns {string}\n */\nexport function useId(idOverride, prefix) {\n // React.useId() is only available from React 17.0.0.\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride ?? (prefix ? `${prefix}-${reactId}` : reactId);\n }\n\n // TODO: uncomment once we enable eslint-plugin-react-compiler // eslint-disable-next-line react-compiler/react-compiler\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride, prefix);\n}"],"names":["globalId","useGlobalId","idOverride","prefix","defaultId","setDefaultId","React","id","maybeReactUseId","SafeReact","useId","reactId"],"mappings":";;AAIA,IAAIA,IAAW;AAGf,SAASC,EAAYC,GAAYC,IAAS,OAAO;AAC/C,QAAM,CAACC,GAAWC,CAAY,IAAIC,EAAM,SAASJ,CAAU,GACrDK,IAAKL,KAAcE;AACzB,SAAAE,EAAM,UAAU,MAAM;AACpB,IAAIF,KAAa,SAKfJ,KAAY,GACZK,EAAa,GAAGF,CAAM,IAAIH,CAAQ,EAAE;AAAA,EAExC,GAAG,CAACI,GAAWD,CAAM,CAAC,GACfI;AACT;AACA,MAAMC,IAAkBC,EAAU;AAQ3B,SAASC,EAAMR,GAAYC,GAAQ;AAExC,MAAIK,MAAoB,QAAW;AACjC,UAAMG,IAAUH,EAAe;AAC/B,WAAON,MAAeC,IAAS,GAAGA,CAAM,IAAIQ,CAAO,KAAKA;AAAA,EAC1D;AAIA,SAAOV,EAAYC,GAAYC,CAAM;AACvC;","x_google_ignoreList":[0]}
|
package/dist/index357.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { lowerPlatform as t, lowerUserAgent as n, maxTouchPoints as i } from "./
|
|
1
|
+
import { lowerPlatform as t, lowerUserAgent as n, maxTouchPoints as i } from "./index422.js";
|
|
2
2
|
const s = /^i(os$|p)/.test(t) || t === "macintel" && i > 1, o = "android", c = t === o || n.includes(o), r = !s && t.startsWith("mac");
|
|
3
3
|
t.startsWith("win");
|
|
4
4
|
const e = r || s;
|
package/dist/index358.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import * as c from "react";
|
|
2
|
-
import { Store as l } from "./
|
|
3
|
-
import { useStore as a } from "./
|
|
4
|
-
import { useStableCallback as f } from "./
|
|
5
|
-
import { useIsoLayoutEffect as u } from "./
|
|
6
|
-
import { NOOP as d } from "./
|
|
2
|
+
import { Store as l } from "./index223.js";
|
|
3
|
+
import { useStore as a } from "./index217.js";
|
|
4
|
+
import { useStableCallback as f } from "./index202.js";
|
|
5
|
+
import { useIsoLayoutEffect as u } from "./index201.js";
|
|
6
|
+
import { NOOP as d } from "./index204.js";
|
|
7
7
|
class g extends l {
|
|
8
8
|
/**
|
|
9
9
|
* Creates a new ReactStore instance.
|
package/dist/index359.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { EMPTY_OBJECT as r } from "./
|
|
1
|
+
import { EMPTY_OBJECT as r } from "./index204.js";
|
|
2
2
|
import { FloatingRootStore as l } from "./index388.js";
|
|
3
3
|
import { getEmptyRootContext as d } from "./index391.js";
|
|
4
4
|
import { createSelector as o } from "./index361.js";
|