@triniwiz/nativescript-masonkit 1.0.0-beta.96 → 1.0.0-beta.98

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.
Files changed (102) hide show
  1. package/DOCS.md +41 -23
  2. package/README.md +15 -0
  3. package/angular/fesm2022/triniwiz-nativescript-masonkit-angular.mjs +30 -1
  4. package/angular/fesm2022/triniwiz-nativescript-masonkit-angular.mjs.map +1 -1
  5. package/common.js +23 -131
  6. package/common.js.map +1 -1
  7. package/framework-registry.d.ts +50 -0
  8. package/framework-registry.js +176 -0
  9. package/framework-registry.js.map +1 -0
  10. package/index.android.d.ts +1 -0
  11. package/index.android.js +1 -0
  12. package/index.android.js.map +1 -1
  13. package/index.d.ts +2 -1
  14. package/index.ios.d.ts +1 -0
  15. package/index.ios.js +1 -0
  16. package/index.ios.js.map +1 -1
  17. package/index.windows.d.ts +1 -0
  18. package/index.windows.js +1 -0
  19. package/index.windows.js.map +1 -1
  20. package/package.json +1 -1
  21. package/platforms/android/masonkit-release.aar +0 -0
  22. package/platforms/ios/Mason.xcframework/Info.plist +5 -5
  23. package/platforms/ios/Mason.xcframework/ios-arm64/Mason.framework/Headers/Mason-Swift.h +5 -2
  24. package/platforms/ios/Mason.xcframework/ios-arm64/Mason.framework/Mason +0 -0
  25. package/platforms/ios/Mason.xcframework/ios-arm64/Mason.framework/Modules/Mason.swiftmodule/Project/arm64-apple-ios.swiftsourceinfo +0 -0
  26. package/platforms/ios/Mason.xcframework/ios-arm64/Mason.framework/Modules/Mason.swiftmodule/arm64-apple-ios.abi.json +36460 -27573
  27. package/platforms/ios/Mason.xcframework/ios-arm64/Mason.framework/Modules/Mason.swiftmodule/arm64-apple-ios.private.swiftinterface +204 -201
  28. package/platforms/ios/Mason.xcframework/ios-arm64/Mason.framework/Modules/Mason.swiftmodule/arm64-apple-ios.swiftdoc +0 -0
  29. package/platforms/ios/Mason.xcframework/ios-arm64/Mason.framework/Modules/Mason.swiftmodule/arm64-apple-ios.swiftinterface +204 -201
  30. package/platforms/ios/Mason.xcframework/ios-arm64/dSYMs/Mason.framework.dSYM/Contents/Resources/DWARF/Mason +0 -0
  31. package/platforms/ios/Mason.xcframework/ios-arm64/dSYMs/Mason.framework.dSYM/Contents/Resources/Relocations/aarch64/Mason.yml +7790 -7739
  32. package/platforms/ios/Mason.xcframework/ios-arm64_x86_64-simulator/Mason.framework/Headers/Mason-Swift.h +5 -2039
  33. package/platforms/ios/Mason.xcframework/ios-arm64_x86_64-simulator/Mason.framework/Mason +0 -0
  34. package/platforms/ios/Mason.xcframework/ios-arm64_x86_64-simulator/Mason.framework/Modules/Mason.swiftmodule/Project/arm64-apple-ios-simulator.swiftsourceinfo +0 -0
  35. package/platforms/ios/Mason.xcframework/ios-arm64_x86_64-simulator/Mason.framework/Modules/Mason.swiftmodule/Project/x86_64-apple-ios-simulator.swiftsourceinfo +0 -0
  36. package/platforms/ios/Mason.xcframework/ios-arm64_x86_64-simulator/Mason.framework/Modules/Mason.swiftmodule/arm64-apple-ios-simulator.abi.json +36460 -27573
  37. package/platforms/ios/Mason.xcframework/ios-arm64_x86_64-simulator/Mason.framework/Modules/Mason.swiftmodule/arm64-apple-ios-simulator.private.swiftinterface +204 -201
  38. package/platforms/ios/Mason.xcframework/ios-arm64_x86_64-simulator/Mason.framework/Modules/Mason.swiftmodule/arm64-apple-ios-simulator.swiftdoc +0 -0
  39. package/platforms/ios/Mason.xcframework/ios-arm64_x86_64-simulator/Mason.framework/Modules/Mason.swiftmodule/arm64-apple-ios-simulator.swiftinterface +204 -201
  40. package/platforms/ios/Mason.xcframework/ios-arm64_x86_64-simulator/Mason.framework/Modules/Mason.swiftmodule/x86_64-apple-ios-simulator.abi.json +36460 -27573
  41. package/platforms/ios/Mason.xcframework/ios-arm64_x86_64-simulator/Mason.framework/Modules/Mason.swiftmodule/x86_64-apple-ios-simulator.private.swiftinterface +204 -201
  42. package/platforms/ios/Mason.xcframework/ios-arm64_x86_64-simulator/Mason.framework/Modules/Mason.swiftmodule/x86_64-apple-ios-simulator.swiftdoc +0 -0
  43. package/platforms/ios/Mason.xcframework/ios-arm64_x86_64-simulator/Mason.framework/Modules/Mason.swiftmodule/x86_64-apple-ios-simulator.swiftinterface +204 -201
  44. package/platforms/ios/Mason.xcframework/ios-arm64_x86_64-simulator/Mason.framework/_CodeSignature/CodeResources +14 -80
  45. package/platforms/ios/Mason.xcframework/ios-arm64_x86_64-simulator/dSYMs/Mason.framework.dSYM/Contents/Resources/DWARF/Mason +0 -0
  46. package/platforms/ios/Mason.xcframework/ios-arm64_x86_64-simulator/dSYMs/Mason.framework.dSYM/Contents/Resources/Relocations/aarch64/Mason.yml +7785 -7734
  47. package/platforms/ios/Mason.xcframework/xros-arm64/Mason.framework/Headers/Mason-Swift.h +5 -2
  48. package/platforms/ios/Mason.xcframework/xros-arm64/Mason.framework/Mason +0 -0
  49. package/platforms/ios/Mason.xcframework/xros-arm64/Mason.framework/Modules/Mason.swiftmodule/Project/arm64-apple-xros.swiftsourceinfo +0 -0
  50. package/platforms/ios/Mason.xcframework/xros-arm64/Mason.framework/Modules/Mason.swiftmodule/arm64-apple-xros.abi.json +36460 -27573
  51. package/platforms/ios/Mason.xcframework/xros-arm64/Mason.framework/Modules/Mason.swiftmodule/arm64-apple-xros.private.swiftinterface +204 -201
  52. package/platforms/ios/Mason.xcframework/xros-arm64/Mason.framework/Modules/Mason.swiftmodule/arm64-apple-xros.swiftdoc +0 -0
  53. package/platforms/ios/Mason.xcframework/xros-arm64/Mason.framework/Modules/Mason.swiftmodule/arm64-apple-xros.swiftinterface +204 -201
  54. package/platforms/ios/Mason.xcframework/xros-arm64/dSYMs/Mason.framework.dSYM/Contents/Resources/DWARF/Mason +0 -0
  55. package/platforms/ios/Mason.xcframework/xros-arm64/dSYMs/Mason.framework.dSYM/Contents/Resources/Relocations/aarch64/Mason.yml +7286 -7233
  56. package/platforms/ios/Mason.xcframework/xros-arm64-simulator/Mason.framework/Headers/Mason-Swift.h +5 -2
  57. package/platforms/ios/Mason.xcframework/xros-arm64-simulator/Mason.framework/Mason +0 -0
  58. package/platforms/ios/Mason.xcframework/xros-arm64-simulator/Mason.framework/Modules/Mason.swiftmodule/Project/arm64-apple-xros-simulator.swiftsourceinfo +0 -0
  59. package/platforms/ios/Mason.xcframework/xros-arm64-simulator/Mason.framework/Modules/Mason.swiftmodule/arm64-apple-xros-simulator.abi.json +36460 -27573
  60. package/platforms/ios/Mason.xcframework/xros-arm64-simulator/Mason.framework/Modules/Mason.swiftmodule/arm64-apple-xros-simulator.private.swiftinterface +204 -201
  61. package/platforms/ios/Mason.xcframework/xros-arm64-simulator/Mason.framework/Modules/Mason.swiftmodule/arm64-apple-xros-simulator.swiftdoc +0 -0
  62. package/platforms/ios/Mason.xcframework/xros-arm64-simulator/Mason.framework/Modules/Mason.swiftmodule/arm64-apple-xros-simulator.swiftinterface +204 -201
  63. package/platforms/ios/Mason.xcframework/xros-arm64-simulator/Mason.framework/_CodeSignature/CodeResources +14 -14
  64. package/platforms/ios/Mason.xcframework/xros-arm64-simulator/dSYMs/Mason.framework.dSYM/Contents/Resources/DWARF/Mason +0 -0
  65. package/platforms/ios/Mason.xcframework/xros-arm64-simulator/dSYMs/Mason.framework.dSYM/Contents/Resources/Relocations/aarch64/Mason.yml +7286 -7233
  66. package/properties.js +1 -1
  67. package/properties.js.map +1 -1
  68. package/references.d.ts +5 -0
  69. package/style.d.ts +4 -4
  70. package/style.js +18 -3
  71. package/style.js.map +1 -1
  72. package/text-runs.d.ts +23 -0
  73. package/text-runs.js +65 -0
  74. package/text-runs.js.map +1 -0
  75. package/typings/android.d.ts +7327 -0
  76. package/typings/objc!Mason.d.ts +3963 -0
  77. package/typings/objc!ObjectiveC.d.ts +1640 -0
  78. package/typings/windows.d.ts +330 -0
  79. package/utils/index.android.d.ts +5 -2
  80. package/utils/index.android.js.map +1 -1
  81. package/utils/index.ios.d.ts +5 -2
  82. package/utils/index.ios.js.map +1 -1
  83. package/utils/index.windows.d.ts +5 -2
  84. package/utils/index.windows.js +5 -2
  85. package/utils/index.windows.js.map +1 -1
  86. package/vue/README.md +66 -0
  87. package/vue/index.d.ts +4 -0
  88. package/vue/index.d.ts.map +1 -0
  89. package/vue/index.js +3 -0
  90. package/vue/index.js.map +1 -0
  91. package/vue/package.json +39 -0
  92. package/vue/src/element-registry.d.ts +18 -0
  93. package/vue/src/element-registry.d.ts.map +1 -0
  94. package/vue/src/element-registry.js +56 -0
  95. package/vue/src/element-registry.js.map +1 -0
  96. package/vue/src/mason-meta.d.ts +7 -0
  97. package/vue/src/mason-meta.d.ts.map +1 -0
  98. package/vue/src/mason-meta.js +91 -0
  99. package/vue/src/mason-meta.js.map +1 -0
  100. package/web.js +11 -1
  101. package/web.js.map +1 -1
  102. package/platforms/ios/Mason.xcframework/ios-arm64_x86_64-simulator/dSYMs/Mason.framework.dSYM/Contents/Resources/Relocations/x86_64/Mason.yml +0 -8201
@@ -1868,2045 +1868,11 @@ typedef SWIFT_ENUM_NAMED(NSInteger, MasonOverflow, "Overflow", open) {
1868
1868
  };
1869
1869
 
1870
1870
  typedef SWIFT_ENUM_NAMED(NSInteger, MasonPosition, "Position", open) {
1871
- MasonPositionRelative = 0,
1872
- MasonPositionAbsolute = 1,
1873
- };
1874
-
1875
- typedef SWIFT_ENUM_NAMED(uint16_t, PseudoState, "PseudoState", open) {
1876
- PseudoStateDefault = 0,
1877
- PseudoStateHover = 0x01,
1878
- PseudoStateActive = 0x02,
1879
- PseudoStateFocus = 0x04,
1880
- PseudoStateFocusWithin = 0x08,
1881
- PseudoStateFocusVisible = 0x10,
1882
- PseudoStateDisabled = 0x40,
1883
- PseudoStateChecked = 0x80,
1884
- };
1885
-
1886
- SWIFT_CLASS_NAMED("Scroll")
1887
- @interface MasonScroll : UIScrollView <MasonElementObjc, UIScrollViewDelegate>
1888
- - (void)didMoveToSuperview;
1889
- - (void)drawRect:(CGRect)rect;
1890
- - (void)layoutSubviews;
1891
- @property (nonatomic, readonly, strong) MasonNode * _Nonnull node;
1892
- @property (nonatomic, readonly, strong) NSCMason * _Nonnull mason;
1893
- @property (nonatomic, readonly, strong) UIView * _Nonnull uiView;
1894
- @property (nonatomic, readonly, strong) MasonStyle * _Nonnull style;
1895
- - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder SWIFT_UNAVAILABLE;
1896
- - (void)scrollViewWillBeginDragging:(UIScrollView * _Nonnull)scrollView;
1897
- - (void)scrollViewDidScroll:(UIScrollView * _Nonnull)scrollView;
1898
- - (void)addView:(UIView * _Nonnull)view;
1899
- - (void)addView:(UIView * _Nonnull)view at:(NSInteger)at;
1900
- - (void)removeView:(UIView * _Nonnull)view;
1901
- - (void)removeViewAt:(NSInteger)index;
1902
- - (void)setSize:(float)width :(float)height;
1903
- - (nonnull instancetype)initWithFrame:(CGRect)frame SWIFT_UNAVAILABLE;
1904
- @end
1905
-
1906
- SWIFT_CLASS_NAMED("SwiftHelpers")
1907
- @interface MasonSwiftHelpers : NSObject
1908
- + (void)markNodeDirty:(id <MasonElementObjc> _Nonnull)element;
1909
- + (BOOL)isNodeDirty:(id <MasonElementObjc> _Nonnull)element SWIFT_WARN_UNUSED_RESULT;
1910
- + (void)configure:(id <MasonElementObjc> _Nonnull)element :(SWIFT_NOESCAPE void (^ _Nonnull)(MasonStyle * _Nonnull))block;
1911
- + (MasonLayout * _Nonnull)layout:(id <MasonElementObjc> _Nonnull)element;
1912
- + (void)compute:(id <MasonElementObjc> _Nonnull)element;
1913
- + (void)compute:(id <MasonElementObjc> _Nonnull)element :(float)width :(float)height;
1914
- + (void)computeMaxContent:(id <MasonElementObjc> _Nonnull)element;
1915
- + (void)computeMinContent:(id <MasonElementObjc> _Nonnull)element;
1916
- + (void)computeWithSize:(id <MasonElementObjc> _Nonnull)element :(float)width :(float)height;
1917
- + (void)computeWithViewSize:(id <MasonElementObjc> _Nonnull)element;
1918
- + (void)computeWithViewSize:(id <MasonElementObjc> _Nonnull)element layout:(BOOL)layout;
1919
- + (void)computeWithMaxContent:(id <MasonElementObjc> _Nonnull)element;
1920
- + (void)computeWithMinContent:(id <MasonElementObjc> _Nonnull)element;
1921
- + (void)attachAndApply:(id <MasonElementObjc> _Nonnull)element;
1922
- + (void)requestLayout:(id <MasonElementObjc> _Nonnull)element;
1923
- + (void)append:(id <MasonElementObjc> _Nonnull)parent :(id <MasonElementObjc> _Nonnull)element;
1924
- + (void)append:(id <MasonElementObjc> _Nonnull)parent text:(NSString * _Nonnull)text;
1925
- + (void)append:(id <MasonElementObjc> _Nonnull)parent node:(MasonNode * _Nonnull)node;
1926
- + (void)append:(id <MasonElementObjc> _Nonnull)parent texts:(NSArray<NSString *> * _Nonnull)texts;
1927
- + (void)append:(id <MasonElementObjc> _Nonnull)parent elements:(NSArray<id <MasonElementObjc>> * _Nonnull)elements;
1928
- + (void)append:(id <MasonElementObjc> _Nonnull)parent nodes:(NSArray<MasonNode *> * _Nonnull)nodes;
1929
- + (void)prepend:(id <MasonElementObjc> _Nonnull)parent :(id <MasonElementObjc> _Nonnull)element;
1930
- + (void)prepend:(id <MasonElementObjc> _Nonnull)parent string:(NSString * _Nonnull)string;
1931
- + (void)prepend:(id <MasonElementObjc> _Nonnull)parent node:(MasonNode * _Nonnull)node;
1932
- + (void)prepend:(id <MasonElementObjc> _Nonnull)parent strings:(NSArray<NSString *> * _Nonnull)strings;
1933
- + (void)prepend:(id <MasonElementObjc> _Nonnull)parent elements:(NSArray<id <MasonElementObjc>> * _Nonnull)elements;
1934
- + (void)prepend:(id <MasonElementObjc> _Nonnull)parent nodes:(NSArray<MasonNode *> * _Nonnull)nodes;
1935
- + (void)addChildAt:(id <MasonElementObjc> _Nonnull)parent text:(NSString * _Nonnull)text :(NSInteger)index;
1936
- + (void)addChildAt:(id <MasonElementObjc> _Nonnull)parent element:(id <MasonElementObjc> _Nonnull)element :(NSInteger)index;
1937
- + (void)addChildAt:(id <MasonElementObjc> _Nonnull)parent node:(MasonNode * _Nonnull)node :(NSInteger)index;
1938
- - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
1939
- @end
1940
-
1941
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonTextAlign, "TextAlign", open) {
1942
- MasonTextAlignAuto = 0,
1943
- MasonTextAlignLeft = 1,
1944
- MasonTextAlignRight = 2,
1945
- MasonTextAlignCenter = 3,
1946
- MasonTextAlignJustify = 4,
1947
- MasonTextAlignStart = 5,
1948
- MasonTextAlignEnd = 6,
1949
- };
1950
-
1951
- SWIFT_CLASS_NAMED("TextEngine")
1952
- @interface MasonTextEngine : NSObject
1953
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
1954
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
1955
- @end
1956
-
1957
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonTextJustify, "TextJustify", open) {
1958
- MasonTextJustifyNone = 0,
1959
- MasonTextJustifyAuto = 1,
1960
- MasonTextJustifyInterWord = 2,
1961
- MasonTextJustifyInterCharacter = 3,
1962
- MasonTextJustifyDistribute = 4,
1963
- };
1964
-
1965
- SWIFT_CLASS_NAMED("TextOverflowCompat")
1966
- @interface MasonTextOverflowCompat : NSObject
1967
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MasonTextOverflowCompat * _Nonnull Clip;)
1968
- + (MasonTextOverflowCompat * _Nonnull)Clip SWIFT_WARN_UNUSED_RESULT;
1969
- + (MasonTextOverflowCompat * _Nonnull)Ellipse:(NSString * _Nullable)value SWIFT_WARN_UNUSED_RESULT;
1970
- + (MasonTextOverflowCompat * _Nonnull)Custom:(NSString * _Nonnull)value SWIFT_WARN_UNUSED_RESULT;
1971
- @property (nonatomic, readonly, copy) NSString * _Nonnull description;
1972
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
1973
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
1974
- @end
1975
-
1976
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonTextTransform, "TextTransform", open) {
1977
- MasonTextTransformNone = 0,
1978
- MasonTextTransformCapitalize = 1,
1979
- MasonTextTransformUppercase = 2,
1980
- MasonTextTransformLowercase = 3,
1981
- MasonTextTransformFullWidth = 4,
1982
- MasonTextTransformFullSizeKana = 5,
1983
- MasonTextTransformMathAuto = 6,
1984
- };
1985
-
1986
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonTextWrap, "TextWrap", open) {
1987
- MasonTextWrapWrap = 0,
1988
- MasonTextWrapNoWrap = 1,
1989
- MasonTextWrapBalance = 2,
1990
- MasonTextWrapPretty = 3,
1991
- };
1992
-
1993
- SWIFT_CLASS_NAMED("TrackSizingFunction")
1994
- @interface TrackSizingFunction : NSObject
1995
- @property (nonatomic, readonly) BOOL isRepeating;
1996
- @property (nonatomic, readonly) id _Nullable value;
1997
- + (TrackSizingFunction * _Nonnull)Single:(MinMax * _Nonnull)value SWIFT_WARN_UNUSED_RESULT;
1998
- + (TrackSizingFunction * _Nonnull)AutoRepeat:(MasonGridTrackRepetition * _Nonnull)gridTrackRepetition :(NSArray<MinMax *> * _Nonnull)value SWIFT_WARN_UNUSED_RESULT;
1999
- @property (nonatomic, readonly, copy) NSString * _Nonnull cssValue;
2000
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
2001
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
2002
- @end
2003
-
2004
- typedef SWIFT_ENUM(uint8_t, TransformOpType, open) {
2005
- TransformOpTypeNone = 0,
2006
- TransformOpTypeTranslate = 1,
2007
- TransformOpTypeTranslateX = 2,
2008
- TransformOpTypeTranslateY = 3,
2009
- TransformOpTypeScale = 4,
2010
- TransformOpTypeScaleX = 5,
2011
- TransformOpTypeScaleY = 6,
2012
- TransformOpTypeRotate = 7,
2013
- TransformOpTypeSkewX = 8,
2014
- TransformOpTypeSkewY = 9,
2015
- };
2016
-
2017
- @interface UIView (SWIFT_EXTENSION(Mason))
2018
- - (UIView * _Nullable)mason_elementFromPoint:(CGFloat)x y:(CGFloat)y SWIFT_WARN_UNUSED_RESULT;
2019
- @end
2020
-
2021
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonWhiteSpace, "WhiteSpace", open) {
2022
- MasonWhiteSpaceNormal = 0,
2023
- MasonWhiteSpacePre = 1,
2024
- MasonWhiteSpacePreWrap = 2,
2025
- MasonWhiteSpacePreLine = 3,
2026
- MasonWhiteSpaceNoWrap = 4,
2027
- MasonWhiteSpaceBreakSpaces = 5,
2028
- };
2029
-
2030
- #endif // defined(__OBJC__)
2031
- #if __has_attribute(external_source_symbol)
2032
- # pragma clang attribute pop
2033
- #endif
2034
- #if defined(__cplusplus)
2035
- #endif
2036
- #pragma clang diagnostic pop
2037
- #endif
2038
-
2039
- #elif defined(__x86_64__) && __x86_64__
2040
- // Generated by Apple Swift version 6.3.1 effective-5.10 (swiftlang-6.3.1.1.2 clang-2100.0.123.102)
2041
- #ifndef MASON_SWIFT_H
2042
- #define MASON_SWIFT_H
2043
- #pragma clang diagnostic push
2044
- #pragma clang diagnostic ignored "-Wgcc-compat"
2045
-
2046
- #if !defined(__has_include)
2047
- # define __has_include(x) 0
2048
- #endif
2049
- #if !defined(__has_attribute)
2050
- # define __has_attribute(x) 0
2051
- #endif
2052
- #if !defined(__has_feature)
2053
- # define __has_feature(x) 0
2054
- #endif
2055
- #if !defined(__has_warning)
2056
- # define __has_warning(x) 0
2057
- #endif
2058
-
2059
- #if __has_include(<swift/objc-prologue.h>)
2060
- # include <swift/objc-prologue.h>
2061
- #endif
2062
-
2063
- #pragma clang diagnostic ignored "-Wauto-import"
2064
- #if defined(__OBJC__)
2065
- #include <Foundation/Foundation.h>
2066
- #endif // defined(__OBJC__)
2067
- #if defined(__cplusplus)
2068
- #include <cstdint>
2069
- #include <cstddef>
2070
- #include <cstdbool>
2071
- #include <cstring>
2072
- #include <stdlib.h>
2073
- #include <new>
2074
- #include <type_traits>
2075
- #else
2076
- #include <stdint.h>
2077
- #include <stddef.h>
2078
- #include <stdbool.h>
2079
- #include <string.h>
2080
- #endif
2081
- #if defined(__cplusplus)
2082
- #pragma clang diagnostic push
2083
- #pragma clang diagnostic ignored "-Wnon-modular-include-in-framework-module"
2084
- #if defined(__arm64e__) && __has_include(<ptrauth.h>)
2085
- # include <ptrauth.h>
2086
- #else
2087
- #pragma clang diagnostic push
2088
- #pragma clang diagnostic ignored "-Wreserved-macro-identifier"
2089
- # ifndef __ptrauth_swift_value_witness_function_pointer
2090
- # define __ptrauth_swift_value_witness_function_pointer(x)
2091
- # endif
2092
- # ifndef __ptrauth_swift_class_method_pointer
2093
- # define __ptrauth_swift_class_method_pointer(x)
2094
- # endif
2095
- #pragma clang diagnostic pop
2096
- #endif
2097
- #pragma clang diagnostic pop
2098
- #endif
2099
-
2100
- #if !defined(SWIFT_TYPEDEFS)
2101
- # define SWIFT_TYPEDEFS 1
2102
- # if __has_include(<uchar.h>)
2103
- # include <uchar.h>
2104
- # elif !defined(__cplusplus)
2105
- typedef unsigned char char8_t;
2106
- typedef uint_least16_t char16_t;
2107
- typedef uint_least32_t char32_t;
2108
- # endif
2109
- typedef float swift_float2 __attribute__((__ext_vector_type__(2)));
2110
- typedef float swift_float3 __attribute__((__ext_vector_type__(3)));
2111
- typedef float swift_float4 __attribute__((__ext_vector_type__(4)));
2112
- typedef double swift_double2 __attribute__((__ext_vector_type__(2)));
2113
- typedef double swift_double3 __attribute__((__ext_vector_type__(3)));
2114
- typedef double swift_double4 __attribute__((__ext_vector_type__(4)));
2115
- typedef int swift_int2 __attribute__((__ext_vector_type__(2)));
2116
- typedef int swift_int3 __attribute__((__ext_vector_type__(3)));
2117
- typedef int swift_int4 __attribute__((__ext_vector_type__(4)));
2118
- typedef unsigned int swift_uint2 __attribute__((__ext_vector_type__(2)));
2119
- typedef unsigned int swift_uint3 __attribute__((__ext_vector_type__(3)));
2120
- typedef unsigned int swift_uint4 __attribute__((__ext_vector_type__(4)));
2121
- #endif
2122
-
2123
- #if !defined(SWIFT_PASTE)
2124
- # define SWIFT_PASTE_HELPER(x, y) x##y
2125
- # define SWIFT_PASTE(x, y) SWIFT_PASTE_HELPER(x, y)
2126
- #endif
2127
- #if !defined(SWIFT_METATYPE)
2128
- # define SWIFT_METATYPE(X) Class
2129
- #endif
2130
- #if !defined(SWIFT_CLASS_PROPERTY)
2131
- # if __has_feature(objc_class_property)
2132
- # define SWIFT_CLASS_PROPERTY(...) __VA_ARGS__
2133
- # else
2134
- # define SWIFT_CLASS_PROPERTY(...)
2135
- # endif
2136
- #endif
2137
- #if !defined(SWIFT_RUNTIME_NAME)
2138
- # if __has_attribute(objc_runtime_name)
2139
- # define SWIFT_RUNTIME_NAME(X) __attribute__((objc_runtime_name(X)))
2140
- # else
2141
- # define SWIFT_RUNTIME_NAME(X)
2142
- # endif
2143
- #endif
2144
- #if !defined(SWIFT_COMPILE_NAME)
2145
- # if __has_attribute(swift_name)
2146
- # define SWIFT_COMPILE_NAME(X) __attribute__((swift_name(X)))
2147
- # else
2148
- # define SWIFT_COMPILE_NAME(X)
2149
- # endif
2150
- #endif
2151
- #if !defined(SWIFT_METHOD_FAMILY)
2152
- # if __has_attribute(objc_method_family)
2153
- # define SWIFT_METHOD_FAMILY(X) __attribute__((objc_method_family(X)))
2154
- # else
2155
- # define SWIFT_METHOD_FAMILY(X)
2156
- # endif
2157
- #endif
2158
- #if !defined(SWIFT_NOESCAPE)
2159
- # if __has_attribute(noescape)
2160
- # define SWIFT_NOESCAPE __attribute__((noescape))
2161
- # else
2162
- # define SWIFT_NOESCAPE
2163
- # endif
2164
- #endif
2165
- #if !defined(SWIFT_RELEASES_ARGUMENT)
2166
- # if __has_attribute(ns_consumed)
2167
- # define SWIFT_RELEASES_ARGUMENT __attribute__((ns_consumed))
2168
- # else
2169
- # define SWIFT_RELEASES_ARGUMENT
2170
- # endif
2171
- #endif
2172
- #if !defined(SWIFT_WARN_UNUSED_RESULT)
2173
- # if __has_attribute(warn_unused_result)
2174
- # define SWIFT_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
2175
- # else
2176
- # define SWIFT_WARN_UNUSED_RESULT
2177
- # endif
2178
- #endif
2179
- #if !defined(SWIFT_NORETURN)
2180
- # if __has_attribute(noreturn)
2181
- # define SWIFT_NORETURN __attribute__((noreturn))
2182
- # else
2183
- # define SWIFT_NORETURN
2184
- # endif
2185
- #endif
2186
- #if !defined(SWIFT_CLASS_EXTRA)
2187
- # define SWIFT_CLASS_EXTRA
2188
- #endif
2189
- #if !defined(SWIFT_PROTOCOL_EXTRA)
2190
- # define SWIFT_PROTOCOL_EXTRA
2191
- #endif
2192
- #if !defined(SWIFT_ENUM_EXTRA)
2193
- # define SWIFT_ENUM_EXTRA
2194
- #endif
2195
- #if !defined(SWIFT_CLASS)
2196
- # if __has_attribute(objc_subclassing_restricted)
2197
- # define SWIFT_CLASS(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) __attribute__((objc_subclassing_restricted)) SWIFT_CLASS_EXTRA
2198
- # define SWIFT_CLASS_NAMED(SWIFT_NAME) __attribute__((objc_subclassing_restricted)) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA
2199
- # else
2200
- # define SWIFT_CLASS(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA
2201
- # define SWIFT_CLASS_NAMED(SWIFT_NAME) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA
2202
- # endif
2203
- #endif
2204
- #if !defined(SWIFT_RESILIENT_CLASS)
2205
- # if __has_attribute(objc_class_stub)
2206
- # define SWIFT_RESILIENT_CLASS(SWIFT_NAME) SWIFT_CLASS(SWIFT_NAME) __attribute__((objc_class_stub))
2207
- # define SWIFT_RESILIENT_CLASS_NAMED(SWIFT_NAME) __attribute__((objc_class_stub)) SWIFT_CLASS_NAMED(SWIFT_NAME)
2208
- # else
2209
- # define SWIFT_RESILIENT_CLASS(SWIFT_NAME) SWIFT_CLASS(SWIFT_NAME)
2210
- # define SWIFT_RESILIENT_CLASS_NAMED(SWIFT_NAME) SWIFT_CLASS_NAMED(SWIFT_NAME)
2211
- # endif
2212
- #endif
2213
- #if !defined(SWIFT_PROTOCOL)
2214
- # define SWIFT_PROTOCOL(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) SWIFT_PROTOCOL_EXTRA
2215
- # define SWIFT_PROTOCOL_NAMED(SWIFT_NAME) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_PROTOCOL_EXTRA
2216
- #endif
2217
- #if !defined(SWIFT_EXTENSION)
2218
- # define SWIFT_EXTENSION(M) SWIFT_PASTE(M##_Swift_, __LINE__)
2219
- #endif
2220
- #if !defined(OBJC_DESIGNATED_INITIALIZER)
2221
- # if __has_attribute(objc_designated_initializer)
2222
- # define OBJC_DESIGNATED_INITIALIZER __attribute__((objc_designated_initializer))
2223
- # else
2224
- # define OBJC_DESIGNATED_INITIALIZER
2225
- # endif
2226
- #endif
2227
- #if !defined(SWIFT_ENUM_ATTR)
2228
- # if __has_attribute(enum_extensibility)
2229
- # define SWIFT_ENUM_ATTR(_extensibility) __attribute__((enum_extensibility(_extensibility)))
2230
- # else
2231
- # define SWIFT_ENUM_ATTR(_extensibility)
2232
- # endif
2233
- #endif
2234
- #if !defined(SWIFT_ENUM)
2235
- # if (defined(__cplusplus) && __cplusplus >= 201103L) || (defined(__STDC_VERSION__) && __STDC_VERSION__ >= 202311L) || __has_feature(objc_fixed_enum)
2236
- # define SWIFT_ENUM(_type, _name, _extensibility) enum _name : _type _name; enum SWIFT_ENUM_ATTR(_extensibility) SWIFT_ENUM_EXTRA _name : _type
2237
- # if __has_feature(generalized_swift_name)
2238
- # define SWIFT_ENUM_NAMED(_type, _name, SWIFT_NAME, _extensibility) enum _name : _type _name SWIFT_COMPILE_NAME(SWIFT_NAME); enum SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_ENUM_ATTR(_extensibility) SWIFT_ENUM_EXTRA _name : _type
2239
- # else
2240
- # define SWIFT_ENUM_NAMED(_type, _name, SWIFT_NAME, _extensibility) SWIFT_ENUM(_type, _name, _extensibility)
2241
- # endif
2242
- # else
2243
- # define SWIFT_ENUM(_type, _name, _extensibility) _type _name; enum
2244
- # define SWIFT_ENUM_NAMED(_type, _name, SWIFT_NAME, _extensibility) SWIFT_ENUM(_type, _name, _extensibility)
2245
- # endif
2246
- #endif
2247
- #if !defined(SWIFT_ENUM_TAG)
2248
- # if (defined(__cplusplus) && __cplusplus >= 201103L) || (defined(__STDC_VERSION__) && __STDC_VERSION__ >= 202311L) || __has_feature(objc_fixed_enum)
2249
- # define SWIFT_ENUM_TAG enum
2250
- # else
2251
- # define SWIFT_ENUM_TAG
2252
- # endif
2253
- #endif
2254
- #if !defined(SWIFT_ENUM_FWD_DECL)
2255
- # if (defined(__cplusplus) && __cplusplus >= 201103L) || (defined(__STDC_VERSION__) && __STDC_VERSION__ >= 202311L) || __has_feature(objc_fixed_enum)
2256
- # define SWIFT_ENUM_FWD_DECL(_type, _name) enum _name : _type;
2257
- # else
2258
- # define SWIFT_ENUM_FWD_DECL(_type, _name) typedef _type _name;
2259
- # endif
2260
- #endif
2261
- #if !defined(SWIFT_UNAVAILABLE)
2262
- # define SWIFT_UNAVAILABLE __attribute__((unavailable))
2263
- #endif
2264
- #if !defined(SWIFT_UNAVAILABLE_MSG)
2265
- # define SWIFT_UNAVAILABLE_MSG(msg) __attribute__((unavailable(msg)))
2266
- #endif
2267
- #if !defined(SWIFT_AVAILABILITY)
2268
- # define SWIFT_AVAILABILITY(plat, ...) __attribute__((availability(plat, __VA_ARGS__)))
2269
- #endif
2270
- #if !defined(SWIFT_AVAILABILITY_DOMAIN)
2271
- # define SWIFT_AVAILABILITY_DOMAIN(dom, ...) __attribute__((availability(domain: dom, __VA_ARGS__)))
2272
- #endif
2273
- #if !defined(SWIFT_WEAK_IMPORT)
2274
- # define SWIFT_WEAK_IMPORT __attribute__((weak_import))
2275
- #endif
2276
- #if !defined(SWIFT_DEPRECATED)
2277
- # define SWIFT_DEPRECATED __attribute__((deprecated))
2278
- #endif
2279
- #if !defined(SWIFT_DEPRECATED_MSG)
2280
- # define SWIFT_DEPRECATED_MSG(...) __attribute__((deprecated(__VA_ARGS__)))
2281
- #endif
2282
- #if !defined(SWIFT_DEPRECATED_OBJC)
2283
- # if __has_feature(attribute_diagnose_if_objc)
2284
- # define SWIFT_DEPRECATED_OBJC(Msg) __attribute__((diagnose_if(1, Msg, "warning")))
2285
- # else
2286
- # define SWIFT_DEPRECATED_OBJC(Msg) SWIFT_DEPRECATED_MSG(Msg)
2287
- # endif
2288
- #endif
2289
- #if defined(__OBJC__)
2290
- #if !defined(IBSegueAction)
2291
- # define IBSegueAction
2292
- #endif
2293
- #endif
2294
- #if !defined(SWIFT_EXTERN)
2295
- # if defined(__cplusplus)
2296
- # define SWIFT_EXTERN extern "C"
2297
- # else
2298
- # define SWIFT_EXTERN extern
2299
- # endif
2300
- #endif
2301
- #if !defined(SWIFT_CALL)
2302
- # define SWIFT_CALL __attribute__((swiftcall))
2303
- #endif
2304
- #if !defined(SWIFT_INDIRECT_RESULT)
2305
- # define SWIFT_INDIRECT_RESULT __attribute__((swift_indirect_result))
2306
- #endif
2307
- #if !defined(SWIFT_CONTEXT)
2308
- # define SWIFT_CONTEXT __attribute__((swift_context))
2309
- #endif
2310
- #if !defined(SWIFT_ERROR_RESULT)
2311
- # define SWIFT_ERROR_RESULT __attribute__((swift_error_result))
2312
- #endif
2313
- #if defined(__cplusplus)
2314
- # define SWIFT_NOEXCEPT noexcept
2315
- #else
2316
- # define SWIFT_NOEXCEPT
2317
- #endif
2318
- #if !defined(SWIFT_C_INLINE_THUNK)
2319
- # if __has_attribute(always_inline)
2320
- # if __has_attribute(nodebug)
2321
- # define SWIFT_C_INLINE_THUNK inline __attribute__((always_inline)) __attribute__((nodebug))
2322
- # else
2323
- # define SWIFT_C_INLINE_THUNK inline __attribute__((always_inline))
2324
- # endif
2325
- # else
2326
- # define SWIFT_C_INLINE_THUNK inline
2327
- # endif
2328
- #endif
2329
- #if defined(_WIN32)
2330
- #if !defined(SWIFT_IMPORT_STDLIB_SYMBOL)
2331
- # define SWIFT_IMPORT_STDLIB_SYMBOL __declspec(dllimport)
2332
- #endif
2333
- #else
2334
- #if !defined(SWIFT_IMPORT_STDLIB_SYMBOL)
2335
- # define SWIFT_IMPORT_STDLIB_SYMBOL
2336
- #endif
2337
- #endif
2338
- #if !__has_feature(nullability)
2339
- # define _Nonnull
2340
- # define _Nullable
2341
- # define _Null_unspecified
2342
- #elif !defined(__OBJC__)
2343
- # pragma clang diagnostic ignored "-Wnullability-extension"
2344
- #endif
2345
- #if !__has_feature(nullability_nullable_result)
2346
- # define _Nullable_result _Nullable
2347
- #endif
2348
- #if __has_feature(objc_modules)
2349
- #if __has_warning("-Watimport-in-framework-header")
2350
- #pragma clang diagnostic ignored "-Watimport-in-framework-header"
2351
- #endif
2352
- #endif
2353
-
2354
- #pragma clang diagnostic ignored "-Wproperty-attribute-mismatch"
2355
- #pragma clang diagnostic ignored "-Wduplicate-method-arg"
2356
- #if __has_warning("-Wpragma-clang-attribute")
2357
- # pragma clang diagnostic ignored "-Wpragma-clang-attribute"
2358
- #endif
2359
- #pragma clang diagnostic ignored "-Wunknown-pragmas"
2360
- #pragma clang diagnostic ignored "-Wnullability"
2361
- #pragma clang diagnostic ignored "-Wdollar-in-identifier-extension"
2362
- #pragma clang diagnostic ignored "-Wunsafe-buffer-usage"
2363
-
2364
- #if __has_attribute(external_source_symbol)
2365
- # pragma push_macro("any")
2366
- # undef any
2367
- # pragma clang attribute push(__attribute__((external_source_symbol(language="Swift", defined_in="Mason",generated_declaration))), apply_to=any(function,enum,objc_interface,objc_category,objc_protocol))
2368
- # pragma pop_macro("any")
2369
- #endif
2370
-
2371
- #if defined(__cplusplus)
2372
- extern "C" {
2373
- #endif
2374
-
2375
- #if defined(__cplusplus)
2376
- } // extern "C"
2377
- #endif
2378
- #if __has_attribute(external_source_symbol)
2379
- # pragma clang attribute pop
2380
- #endif
2381
- #if defined(__OBJC__)
2382
- #if __has_feature(objc_modules)
2383
- #if __has_warning("-Watimport-in-framework-header")
2384
- #pragma clang diagnostic ignored "-Watimport-in-framework-header"
2385
- #endif
2386
- @import CoreFoundation;
2387
- @import CoreGraphics;
2388
- @import Foundation;
2389
- @import ObjectiveC;
2390
- @import QuartzCore;
2391
- @import UIKit;
2392
- #endif
2393
-
2394
- #endif // defined(__OBJC__)
2395
- #pragma clang diagnostic ignored "-Wproperty-attribute-mismatch"
2396
- #pragma clang diagnostic ignored "-Wduplicate-method-arg"
2397
- #if __has_warning("-Wpragma-clang-attribute")
2398
- # pragma clang diagnostic ignored "-Wpragma-clang-attribute"
2399
- #endif
2400
- #pragma clang diagnostic ignored "-Wunknown-pragmas"
2401
- #pragma clang diagnostic ignored "-Wnullability"
2402
- #pragma clang diagnostic ignored "-Wdollar-in-identifier-extension"
2403
- #pragma clang diagnostic ignored "-Wunsafe-buffer-usage"
2404
-
2405
- #if __has_attribute(external_source_symbol)
2406
- # pragma push_macro("any")
2407
- # undef any
2408
- # pragma clang attribute push(__attribute__((external_source_symbol(language="Swift", defined_in="Mason",generated_declaration))), apply_to=any(function,enum,objc_interface,objc_category,objc_protocol))
2409
- # pragma pop_macro("any")
2410
- #endif
2411
-
2412
- #if defined(__OBJC__)
2413
-
2414
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonAlign, "Align", open) {
2415
- MasonAlignAuto = 0,
2416
- MasonAlignLeft = 1,
2417
- MasonAlignRight = 2,
2418
- MasonAlignCenter = 3,
2419
- };
2420
-
2421
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonAlignContent, "AlignContent", open) {
2422
- MasonAlignContentNormal = -1,
2423
- MasonAlignContentStart = 0,
2424
- MasonAlignContentEnd = 1,
2425
- MasonAlignContentCenter = 2,
2426
- MasonAlignContentStretch = 3,
2427
- MasonAlignContentSpaceBetween = 4,
2428
- MasonAlignContentSpaceAround = 5,
2429
- MasonAlignContentSpaceEvenly = 6,
2430
- MasonAlignContentFlexStart = 7,
2431
- MasonAlignContentFlexEnd = 8,
2432
- };
2433
-
2434
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonAlignItems, "AlignItems", open) {
2435
- MasonAlignItemsNormal = -1,
2436
- MasonAlignItemsStart = 0,
2437
- MasonAlignItemsEnd = 1,
2438
- MasonAlignItemsCenter = 2,
2439
- MasonAlignItemsBaseline = 3,
2440
- MasonAlignItemsStretch = 4,
2441
- MasonAlignItemsFlexStart = 5,
2442
- MasonAlignItemsFlexEnd = 6,
2443
- };
2444
-
2445
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonAlignSelf, "AlignSelf", open) {
2446
- MasonAlignSelfNormal = -1,
2447
- MasonAlignSelfStart = 0,
2448
- MasonAlignSelfEnd = 1,
2449
- MasonAlignSelfCenter = 2,
2450
- MasonAlignSelfBaseline = 3,
2451
- MasonAlignSelfStretch = 4,
2452
- MasonAlignSelfFlexStart = 5,
2453
- MasonAlignSelfFlexEnd = 6,
2454
- };
2455
-
2456
- @class NSCoder;
2457
- SWIFT_CLASS("_TtC5Mason17BackgroundCALayer")
2458
- @interface BackgroundCALayer : CALayer
2459
- - (void)drawInContext:(CGContextRef _Nonnull)ctx;
2460
- - (void)layoutSublayers;
2461
- - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
2462
- - (nonnull instancetype)initWithLayer:(id _Nonnull)layer OBJC_DESIGNATED_INITIALIZER;
2463
- - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
2464
- @end
2465
-
2466
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonBoxSizing, "BoxSizing", open) {
2467
- MasonBoxSizingBorderBox = 0,
2468
- MasonBoxSizingContentBox = 1,
2469
- };
2470
-
2471
- @class MasonTextEngine;
2472
- @class MasonNode;
2473
- SWIFT_PROTOCOL_NAMED("TextContainer")
2474
- @protocol MasonTextContainer <NSObject>
2475
- @property (nonatomic, readonly, strong) MasonTextEngine * _Nonnull engine;
2476
- @property (nonatomic, readonly, strong) MasonNode * _Nonnull node;
2477
- - (void)onStyleChange:(uint64_t)low :(uint64_t)high;
2478
- @end
2479
-
2480
- @class MasonStyle;
2481
- @class UIView;
2482
- SWIFT_PROTOCOL("_TtP5Mason16MasonElementObjc_")
2483
- @protocol MasonElementObjc <NSObject>
2484
- @property (nonatomic, readonly, strong) MasonStyle * _Nonnull style;
2485
- @property (nonatomic, readonly, strong) MasonNode * _Nonnull node;
2486
- @property (nonatomic, readonly, strong) UIView * _Nonnull uiView;
2487
- @end
2488
-
2489
- @class NSCMason;
2490
- @class NSString;
2491
- @class NSMutableData;
2492
- SWIFT_CLASS_NAMED("Button")
2493
- @interface MasonButton : UIControl <MasonElementObjc, MasonTextContainer>
2494
- @property (nonatomic, readonly, strong) MasonNode * _Nonnull node;
2495
- @property (nonatomic, readonly, strong) NSCMason * _Nonnull mason;
2496
- @property (nonatomic, strong) MasonTextEngine * _Nonnull engine;
2497
- @property (nonatomic, readonly, strong) UIView * _Nonnull uiView;
2498
- @property (nonatomic, readonly, strong) MasonStyle * _Nonnull style;
2499
- /// Text content - sets or gets the concatenated text from all text nodes
2500
- @property (nonatomic, copy) NSString * _Nonnull textContent;
2501
- - (void)requestLayout;
2502
- - (void)addView:(UIView * _Nonnull)view;
2503
- - (void)addView:(UIView * _Nonnull)view at:(NSInteger)at;
2504
- - (void)removeView:(UIView * _Nonnull)view;
2505
- - (void)removeViewAt:(NSInteger)index;
2506
- - (void)removeAllViews;
2507
- - (void)layoutSubviews;
2508
- - (void)drawRect:(CGRect)rect;
2509
- @property (nonatomic, readonly, strong) NSMutableData * _Nonnull textValues;
2510
- - (void)onStyleChange:(uint64_t)low :(uint64_t)high;
2511
- - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
2512
- - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder SWIFT_UNAVAILABLE;
2513
- @end
2514
-
2515
- @class UITouch;
2516
- @class UIEvent;
2517
- @class UIWindow;
2518
- @interface MasonButton (SWIFT_EXTENSION(Mason))
2519
- - (void)touchesBegan:(NSSet<UITouch *> * _Nonnull)touches withEvent:(UIEvent * _Nullable)event;
2520
- - (void)touchesEnded:(NSSet<UITouch *> * _Nonnull)touches withEvent:(UIEvent * _Nullable)event;
2521
- - (void)touchesCancelled:(NSSet<UITouch *> * _Nonnull)touches withEvent:(UIEvent * _Nullable)event;
2522
- - (void)touchesMoved:(NSSet<UITouch *> * _Nonnull)touches withEvent:(UIEvent * _Nullable)event;
2523
- - (void)willMoveToWindow:(UIWindow * _Nullable)newWindow;
2524
- @end
2525
-
2526
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonClear, "Clear", open) {
2527
- MasonClearNone = 0,
2528
- MasonClearLeft = 1,
2529
- MasonClearRight = 2,
2530
- MasonClearBoth = 3,
2531
- };
2532
-
2533
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonDecorationLine, "DecorationLine", open) {
2534
- MasonDecorationLineNone = 0,
2535
- MasonDecorationLineUnderline = 1,
2536
- MasonDecorationLineOverline = 2,
2537
- MasonDecorationLineLineThrough = 3,
2538
- };
2539
-
2540
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonDecorationStyle, "DecorationStyle", open) {
2541
- MasonDecorationStyleSolid = 0,
2542
- MasonDecorationStyleDouble = 1,
2543
- MasonDecorationStyleDotted = 2,
2544
- MasonDecorationStyleDashed = 3,
2545
- MasonDecorationStyleWavy = 4,
2546
- };
2547
-
2548
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonDirection, "Direction", open) {
2549
- MasonDirectionInherit = 0,
2550
- MasonDirectionLTR = 1,
2551
- MasonDirectionRTL = 2,
2552
- };
2553
-
2554
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonDisplay, "Display", open) {
2555
- MasonDisplayNone = 0,
2556
- MasonDisplayFlex = 1,
2557
- MasonDisplayGrid = 2,
2558
- MasonDisplayBlock = 3,
2559
- MasonDisplayInline = 4,
2560
- MasonDisplayInlineBlock = 5,
2561
- MasonDisplayInlineFlex = 6,
2562
- MasonDisplayInlineGrid = 7,
2563
- };
2564
-
2565
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonFlexDirection, "FlexDirection", open) {
2566
- MasonFlexDirectionRow = 0,
2567
- MasonFlexDirectionColumn = 1,
2568
- MasonFlexDirectionRowReverse = 2,
2569
- MasonFlexDirectionColumnReverse = 3,
2570
- };
2571
-
2572
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonFlexWrap, "FlexWrap", open) {
2573
- MasonFlexWrapNoWrap = 0,
2574
- MasonFlexWrapWrap = 1,
2575
- MasonFlexWrapWrapReverse = 2,
2576
- MasonFlexWrapBalance = 3,
2577
- MasonFlexWrapBalanceReverse = 4,
2578
- };
2579
-
2580
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonFontStyle, "FontStyle", open) {
2581
- MasonFontStyleNormal = 0,
2582
- MasonFontStyleItalic = 1,
2583
- MasonFontStyleOblique = 2,
2584
- };
2585
-
2586
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonGridAutoFlowWrap, "GridAutoFlow", open) {
2587
- MasonGridAutoFlowWrapRow = 0,
2588
- MasonGridAutoFlowWrapColumn = 1,
2589
- MasonGridAutoFlowWrapRowDense = 2,
2590
- MasonGridAutoFlowWrapColumnDense = 3,
2591
- };
2592
-
2593
- SWIFT_ENUM_FWD_DECL(NSInteger, MasonGridPlacementCompatType)
2594
- SWIFT_CLASS_NAMED("GridPlacementCompat")
2595
- @interface GridPlacementCompat : NSObject
2596
- - (nonnull instancetype)initWithSpan:(int16_t)span OBJC_DESIGNATED_INITIALIZER;
2597
- - (nonnull instancetype)initWithLine:(int16_t)line OBJC_DESIGNATED_INITIALIZER;
2598
- @property (nonatomic, readonly) enum MasonGridPlacementCompatType type;
2599
- @property (nonatomic, readonly) int16_t value;
2600
- @property (nonatomic, readonly, copy) NSString * _Nonnull cssValue;
2601
- @property (nonatomic, readonly, copy) NSString * _Nullable jsonValue;
2602
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) GridPlacementCompat * _Nonnull Auto;)
2603
- + (GridPlacementCompat * _Nonnull)Auto SWIFT_WARN_UNUSED_RESULT;
2604
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
2605
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
2606
- @end
2607
-
2608
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonGridPlacementCompatType, "GridPlacementCompatType", open) {
2609
- MasonGridPlacementCompatTypeAuto = 0,
2610
- MasonGridPlacementCompatTypeLine = 1,
2611
- MasonGridPlacementCompatTypeSpan = 2,
2612
- };
2613
-
2614
- SWIFT_CLASS_NAMED("GridTrackRepetition")
2615
- @interface MasonGridTrackRepetition : NSObject
2616
- @property (nonatomic, readonly, copy) NSString * _Nonnull cssValue;
2617
- @property (nonatomic, readonly) int32_t type;
2618
- @property (nonatomic, readonly) uint16_t value;
2619
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MasonGridTrackRepetition * _Nonnull AutoFill;)
2620
- + (MasonGridTrackRepetition * _Nonnull)AutoFill SWIFT_WARN_UNUSED_RESULT;
2621
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MasonGridTrackRepetition * _Nonnull AutoFit;)
2622
- + (MasonGridTrackRepetition * _Nonnull)AutoFit SWIFT_WARN_UNUSED_RESULT;
2623
- + (MasonGridTrackRepetition * _Nonnull)Count:(uint16_t)value SWIFT_WARN_UNUSED_RESULT;
2624
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
2625
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
2626
- @end
2627
-
2628
- SWIFT_CLASS_NAMED("HTMLParser")
2629
- @interface MasonHTMLParser : NSObject
2630
- - (nonnull instancetype)initWithMason:(NSCMason * _Nonnull)mason OBJC_DESIGNATED_INITIALIZER;
2631
- /// Parses an HTML string and returns a list of root-level MasonElement/MasonNode children.
2632
- - (NSArray<MasonNode *> * _Nonnull)parse:(NSString * _Nonnull)html SWIFT_WARN_UNUSED_RESULT;
2633
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
2634
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
2635
- @end
2636
-
2637
- SWIFT_ENUM_FWD_DECL(NSInteger, MasonLoadingState)
2638
- @class UIImage;
2639
- SWIFT_CLASS_NAMED("Img")
2640
- @interface MasonImg : UIView <MasonElementObjc>
2641
- @property (nonatomic, readonly, strong) MasonNode * _Nonnull node;
2642
- @property (nonatomic, readonly, strong) NSCMason * _Nonnull mason;
2643
- @property (nonatomic, readonly, strong) UIView * _Nonnull uiView;
2644
- @property (nonatomic, readonly, strong) MasonStyle * _Nonnull style;
2645
- @property (nonatomic, copy) void (^ _Nullable didLayout)(void);
2646
- @property (nonatomic, copy) void (^ _Nullable onStateChange)(enum MasonLoadingState, NSError * _Nullable);
2647
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly) Class _Nonnull layerClass;)
2648
- + (Class _Nonnull)layerClass SWIFT_WARN_UNUSED_RESULT;
2649
- @property (nonatomic, strong) UIImage * _Nullable image;
2650
- - (void)requestLayout;
2651
- @property (nonatomic, copy) NSString * _Nullable src;
2652
- - (void)updateImage:(UIImage * _Nullable)image;
2653
- - (void)layoutSubviews;
2654
- - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder SWIFT_UNAVAILABLE;
2655
- - (nonnull instancetype)initWithFrame:(CGRect)frame SWIFT_UNAVAILABLE;
2656
- @end
2657
-
2658
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonJustifyContent, "JustifyContent", open) {
2659
- MasonJustifyContentNormal = -1,
2660
- MasonJustifyContentStart = 0,
2661
- MasonJustifyContentEnd = 1,
2662
- MasonJustifyContentCenter = 2,
2663
- MasonJustifyContentStretch = 3,
2664
- MasonJustifyContentSpaceBetween = 4,
2665
- MasonJustifyContentSpaceAround = 5,
2666
- MasonJustifyContentSpaceEvenly = 6,
2667
- MasonJustifyContentFlexStart = 7,
2668
- MasonJustifyContentFlexEnd = 8,
2669
- };
2670
-
2671
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonJustifyItems, "JustifyItems", open) {
2672
- MasonJustifyItemsNormal = -1,
2673
- MasonJustifyItemsStart = 0,
2674
- MasonJustifyItemsEnd = 1,
2675
- MasonJustifyItemsCenter = 2,
2676
- MasonJustifyItemsBaseline = 3,
2677
- MasonJustifyItemsStretch = 4,
2678
- MasonJustifyItemsFlexStart = 5,
2679
- MasonJustifyItemsFlexEnd = 6,
2680
- };
2681
-
2682
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonJustifySelf, "JustifySelf", open) {
2683
- MasonJustifySelfNormal = -1,
2684
- MasonJustifySelfStart = 0,
2685
- MasonJustifySelfEnd = 1,
2686
- MasonJustifySelfCenter = 2,
2687
- MasonJustifySelfBaseline = 3,
2688
- MasonJustifySelfStretch = 4,
2689
- MasonJustifySelfFlexStart = 5,
2690
- MasonJustifySelfFlexEnd = 6,
2691
- };
2692
-
2693
- SWIFT_CLASS_NAMED("LineGridPlacementCompat")
2694
- @interface LineGridPlacementCompat : NSObject
2695
- @property (nonatomic, readonly, strong) GridPlacementCompat * _Nonnull start;
2696
- @property (nonatomic, readonly, strong) GridPlacementCompat * _Nonnull end;
2697
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
2698
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
2699
- @end
2700
-
2701
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonLineHeight, "LineHeight", open) {
2702
- MasonLineHeightNormal = 0,
2703
- MasonLineHeightPre = 1,
2704
- MasonLineHeightPreWrap = 2,
2705
- MasonLineHeightPreLine = 3,
2706
- };
2707
-
2708
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonListStylePosition, "ListStylePosition", open) {
2709
- MasonListStylePositionOutside = 0,
2710
- MasonListStylePositionInside = 1,
2711
- };
2712
-
2713
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonListStyleType, "ListStyleType", open) {
2714
- MasonListStyleTypeNone = 0,
2715
- MasonListStyleTypeCustom = 1,
2716
- MasonListStyleTypeDisc = 2,
2717
- MasonListStyleTypeCircle = 3,
2718
- MasonListStyleTypeSquare = 4,
2719
- MasonListStyleTypeDecimal = 5,
2720
- };
2721
-
2722
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonLoadingState, "LoadingState", open) {
2723
- MasonLoadingStateLoading = 0,
2724
- MasonLoadingStateLoaded = 1,
2725
- MasonLoadingStateError = 2,
2726
- };
2727
-
2728
- SWIFT_CLASS_NAMED("MasonBr")
2729
- @interface MasonBr : NSObject <MasonElementObjc>
2730
- @property (nonatomic, readonly, strong) NSCMason * _Nonnull mason;
2731
- @property (nonatomic, strong) MasonNode * _Nonnull node;
2732
- @property (nonatomic, readonly, strong) UIView * _Nonnull uiView;
2733
- @property (nonatomic, readonly, strong) MasonStyle * _Nonnull style;
2734
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
2735
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
2736
- @end
2737
-
2738
- SWIFT_PROTOCOL("_TtP5Mason18MasonCharacterData_")
2739
- @protocol MasonCharacterData
2740
- @property (nonatomic, copy) NSString * _Nonnull data;
2741
- @property (nonatomic, readonly) NSInteger length;
2742
- - (nonnull instancetype)appendData:(NSString * _Nonnull)s;
2743
- - (nonnull instancetype)insertData:(NSString * _Nonnull)s at:(NSInteger)offset;
2744
- - (nonnull instancetype)deleteDataWithOffset:(NSInteger)offset count:(NSInteger)count;
2745
- - (nonnull instancetype)replaceDataWithOffset:(NSInteger)offset count:(NSInteger)count with:(NSString * _Nonnull)s;
2746
- - (NSString * _Nonnull)substringDataWithOffset:(NSInteger)offset count:(NSInteger)count SWIFT_WARN_UNUSED_RESULT;
2747
- - (nonnull instancetype)deleteDataWithRange:(NSRange)range;
2748
- - (nonnull instancetype)replaceDataWithRange:(NSRange)range with:(NSString * _Nonnull)s;
2749
- @end
2750
-
2751
- SWIFT_ENUM_FWD_DECL(NSInteger, MasonDimensionCompatType)
2752
- SWIFT_CLASS_NAMED("MasonDimensionCompat")
2753
- @interface MasonDimensionCompat : NSObject
2754
- - (nonnull instancetype)initWithPoints:(float)points OBJC_DESIGNATED_INITIALIZER;
2755
- - (nonnull instancetype)initWithPercent:(float)percent OBJC_DESIGNATED_INITIALIZER;
2756
- - (nonnull instancetype)initWithFitContentPoints:(float)fitContentPoints OBJC_DESIGNATED_INITIALIZER;
2757
- - (nonnull instancetype)initWithFitContentPercent:(float)fitContentPercent OBJC_DESIGNATED_INITIALIZER;
2758
- @property (nonatomic, readonly) enum MasonDimensionCompatType type;
2759
- @property (nonatomic, readonly) float value;
2760
- @property (nonatomic, readonly, copy) NSString * _Nonnull cssValue;
2761
- @property (nonatomic, readonly, copy) NSString * _Nullable jsonValue;
2762
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MasonDimensionCompat * _Nonnull Auto;)
2763
- + (MasonDimensionCompat * _Nonnull)Auto SWIFT_WARN_UNUSED_RESULT;
2764
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MasonDimensionCompat * _Nonnull MinContent;)
2765
- + (MasonDimensionCompat * _Nonnull)MinContent SWIFT_WARN_UNUSED_RESULT;
2766
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MasonDimensionCompat * _Nonnull MaxContent;)
2767
- + (MasonDimensionCompat * _Nonnull)MaxContent SWIFT_WARN_UNUSED_RESULT;
2768
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MasonDimensionCompat * _Nonnull FitContent;)
2769
- + (MasonDimensionCompat * _Nonnull)FitContent SWIFT_WARN_UNUSED_RESULT;
2770
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MasonDimensionCompat * _Nonnull Stretch;)
2771
- + (MasonDimensionCompat * _Nonnull)Stretch SWIFT_WARN_UNUSED_RESULT;
2772
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MasonDimensionCompat * _Nonnull Content;)
2773
- + (MasonDimensionCompat * _Nonnull)Content SWIFT_WARN_UNUSED_RESULT;
2774
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MasonDimensionCompat * _Nonnull Zero;)
2775
- + (MasonDimensionCompat * _Nonnull)Zero SWIFT_WARN_UNUSED_RESULT;
2776
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
2777
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
2778
- @end
2779
-
2780
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonDimensionCompatType, "MasonDimensionCompatType", open) {
2781
- MasonDimensionCompatTypeAuto = 0,
2782
- MasonDimensionCompatTypePoints = 1,
2783
- MasonDimensionCompatTypePercent = 2,
2784
- MasonDimensionCompatTypeMinContent = 3,
2785
- MasonDimensionCompatTypeMaxContent = 4,
2786
- MasonDimensionCompatTypeFitContent = 5,
2787
- MasonDimensionCompatTypeFitContentPoints = 6,
2788
- MasonDimensionCompatTypeFitContentPercent = 7,
2789
- MasonDimensionCompatTypeStretch = 8,
2790
- MasonDimensionCompatTypeContent = 9,
2791
- };
2792
-
2793
- SWIFT_CLASS_NAMED("MasonDimensionPointCompat")
2794
- @interface MasonDimensionPointCompat : NSObject
2795
- @property (nonatomic, strong) MasonDimensionCompat * _Nonnull x;
2796
- @property (nonatomic, strong) MasonDimensionCompat * _Nonnull y;
2797
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
2798
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
2799
- @end
2800
-
2801
- SWIFT_CLASS_NAMED("MasonDimensionRectCompat")
2802
- @interface MasonDimensionRectCompat : NSObject
2803
- @property (nonatomic, strong) MasonDimensionCompat * _Nonnull left;
2804
- @property (nonatomic, strong) MasonDimensionCompat * _Nonnull right;
2805
- @property (nonatomic, strong) MasonDimensionCompat * _Nonnull top;
2806
- @property (nonatomic, strong) MasonDimensionCompat * _Nonnull bottom;
2807
- - (nonnull instancetype)init:(MasonDimensionCompat * _Nonnull)left :(MasonDimensionCompat * _Nonnull)top :(MasonDimensionCompat * _Nonnull)right :(MasonDimensionCompat * _Nonnull)bottom OBJC_DESIGNATED_INITIALIZER;
2808
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
2809
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
2810
- @end
2811
-
2812
- SWIFT_CLASS_NAMED("MasonDimensionSizeCompat")
2813
- @interface MasonDimensionSizeCompat : NSObject
2814
- @property (nonatomic, strong) MasonDimensionCompat * _Nonnull width;
2815
- @property (nonatomic, strong) MasonDimensionCompat * _Nonnull height;
2816
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
2817
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
2818
- @end
2819
-
2820
- SWIFT_CLASS_NAMED("MasonDocument")
2821
- @interface MasonDocument : NSObject
2822
- @property (nonatomic, readonly, strong) MasonNode * _Nonnull node;
2823
- @property (nonatomic, readonly, strong) NSCMason * _Nonnull mason;
2824
- - (nonnull instancetype)initWithMason:(NSCMason * _Nonnull)instance OBJC_DESIGNATED_INITIALIZER;
2825
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
2826
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
2827
- @end
2828
-
2829
- @class MasonEventOptions;
2830
- SWIFT_CLASS_NAMED("MasonEvent")
2831
- @interface MasonEvent : NSObject
2832
- @property (nonatomic, readonly, copy) NSString * _Nonnull type;
2833
- @property (nonatomic, readonly) BOOL bubbles;
2834
- @property (nonatomic, readonly) BOOL cancelable;
2835
- @property (nonatomic, readonly) BOOL isComposing;
2836
- @property (nonatomic, readonly) double timeStamp;
2837
- @property (nonatomic, readonly) BOOL defaultPrevented;
2838
- @property (nonatomic, readonly) BOOL propagationStopped;
2839
- @property (nonatomic, readonly) BOOL immediatePropagationStopped;
2840
- @property (nonatomic, readonly) id _Nullable target;
2841
- @property (nonatomic, readonly) id _Nullable currentTarget;
2842
- - (nonnull instancetype)initWithType:(NSString * _Nonnull)eventType bubbles:(BOOL)eventBubbles cancelable:(BOOL)eventCancelable options:(MasonEventOptions * _Nullable)options OBJC_DESIGNATED_INITIALIZER;
2843
- - (void)preventDefault;
2844
- - (void)stopPropagation;
2845
- - (void)stopImmediatePropagation;
2846
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
2847
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
2848
- @end
2849
-
2850
- SWIFT_CLASS_NAMED("MasonEventOptions")
2851
- @interface MasonEventOptions : NSObject
2852
- @property (nonatomic) BOOL isComposing;
2853
- - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
2854
- - (nonnull instancetype)initWithIsComposing:(BOOL)isComposing OBJC_DESIGNATED_INITIALIZER;
2855
- @end
2856
-
2857
- @class NSURL;
2858
- SWIFT_CLASS_NAMED("MasonFileInputEvent")
2859
- @interface MasonFileInputEvent : MasonEvent
2860
- @property (nonatomic, readonly, copy) NSString * _Nullable data;
2861
- @property (nonatomic, readonly, copy) NSString * _Nullable inputType;
2862
- @property (nonatomic, readonly, copy) NSArray<NSURL *> * _Nonnull rawData;
2863
- - (nonnull instancetype)initWithType:(NSString * _Nonnull)type data:(NSString * _Nullable)inputData inputType:(NSString * _Nullable)masonInputType options:(MasonEventOptions * _Nullable)options rawData:(NSArray<NSURL *> * _Nonnull)inputRawData OBJC_DESIGNATED_INITIALIZER;
2864
- - (nonnull instancetype)initWithType:(NSString * _Nonnull)eventType bubbles:(BOOL)eventBubbles cancelable:(BOOL)eventCancelable options:(MasonEventOptions * _Nullable)options SWIFT_UNAVAILABLE;
2865
- @end
2866
-
2867
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonFloat, "MasonFloat", open) {
2868
- MasonFloatNone = 0,
2869
- MasonFloatLeft = 1,
2870
- MasonFloatRight = 2,
2871
- };
2872
-
2873
- SWIFT_CLASS("_TtC5Mason15MasonImageLayer")
2874
- @interface MasonImageLayer : CALayer
2875
- - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
2876
- - (nonnull instancetype)initWithLayer:(id _Nonnull)layer OBJC_DESIGNATED_INITIALIZER;
2877
- - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder SWIFT_UNAVAILABLE;
2878
- - (void)drawInContext:(CGContextRef _Nonnull)context;
2879
- - (void)layoutSublayers;
2880
- @end
2881
-
2882
- SWIFT_ENUM_FWD_DECL(int8_t, MasonInputType)
2883
- @class NSDate;
2884
- SWIFT_CLASS_NAMED("MasonInput")
2885
- @interface MasonInput : UIView
2886
- - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder SWIFT_UNAVAILABLE;
2887
- @property (nonatomic, readonly, strong) MasonNode * _Nonnull node;
2888
- @property (nonatomic, readonly, strong) NSCMason * _Nonnull mason;
2889
- @property (nonatomic) BOOL multiple;
2890
- @property (nonatomic, copy) NSString * _Nonnull accept;
2891
- @property (nonatomic, readonly, strong) UIView * _Nonnull uiView;
2892
- @property (nonatomic, readonly, strong) MasonStyle * _Nonnull style;
2893
- @property (nonatomic) enum MasonInputType type;
2894
- @property (nonatomic) int32_t size;
2895
- @property (nonatomic, copy) NSString * _Nonnull value;
2896
- @property (nonatomic) double valueAsNumber;
2897
- @property (nonatomic, copy) NSDate * _Nullable valueAsDate;
2898
- @property (nonatomic, copy) NSString * _Nonnull placeholder;
2899
- - (void)drawRect:(CGRect)rect;
2900
- - (void)layoutSubviews;
2901
- - (nonnull instancetype)initWithFrame:(CGRect)frame SWIFT_UNAVAILABLE;
2902
- @end
2903
-
2904
- SWIFT_CLASS_NAMED("MasonInputEvent")
2905
- @interface MasonInputEvent : MasonEvent
2906
- @property (nonatomic, readonly, copy) NSString * _Nullable data;
2907
- @property (nonatomic, readonly, copy) NSString * _Nullable inputType;
2908
- - (nonnull instancetype)initWithType:(NSString * _Nonnull)type data:(NSString * _Nullable)inputData inputType:(NSString * _Nullable)masonInputType options:(MasonEventOptions * _Nullable)options OBJC_DESIGNATED_INITIALIZER;
2909
- - (nonnull instancetype)initWithType:(NSString * _Nonnull)eventType bubbles:(BOOL)eventBubbles cancelable:(BOOL)eventCancelable options:(MasonEventOptions * _Nullable)options SWIFT_UNAVAILABLE;
2910
- @end
2911
-
2912
- typedef SWIFT_ENUM_NAMED(int8_t, MasonInputType, "MasonInputType", open) {
2913
- MasonInputTypeText = 0,
2914
- MasonInputTypeButton = 1,
2915
- MasonInputTypeCheckbox = 2,
2916
- MasonInputTypeEmail = 3,
2917
- MasonInputTypePassword = 4,
2918
- MasonInputTypeDate = 5,
2919
- MasonInputTypeRadio = 6,
2920
- MasonInputTypeNumber = 7,
2921
- MasonInputTypeRange = 8,
2922
- MasonInputTypeTel = 9,
2923
- MasonInputTypeUrl = 10,
2924
- MasonInputTypeColor = 11,
2925
- MasonInputTypeFile = 12,
2926
- MasonInputTypeSubmit = 13,
2927
- MasonInputTypeSearch = 14,
2928
- MasonInputTypeTime = 15,
2929
- MasonInputTypeDatetimeLocal = 16,
2930
- MasonInputTypeMonth = 17,
2931
- MasonInputTypeWeek = 18,
2932
- MasonInputTypeReset = 19,
2933
- };
2934
-
2935
- @class MasonRectHelper;
2936
- @class MasonSizeHelper;
2937
- SWIFT_CLASS_NAMED("MasonLayout")
2938
- @interface MasonLayout : NSObject
2939
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MasonLayout * _Nonnull empty;)
2940
- + (MasonLayout * _Nonnull)empty SWIFT_WARN_UNUSED_RESULT;
2941
- @property (nonatomic, readonly) float x;
2942
- @property (nonatomic, readonly) float y;
2943
- @property (nonatomic, readonly) float width;
2944
- @property (nonatomic, readonly) float height;
2945
- @property (nonatomic, readonly) float borderTop;
2946
- @property (nonatomic, readonly) float borderRight;
2947
- @property (nonatomic, readonly) float borderBottom;
2948
- @property (nonatomic, readonly) float borderLeft;
2949
- @property (nonatomic, readonly) float marginTop;
2950
- @property (nonatomic, readonly) float marginRight;
2951
- @property (nonatomic, readonly) float marginBottom;
2952
- @property (nonatomic, readonly) float marginLeft;
2953
- @property (nonatomic, readonly) float paddingTop;
2954
- @property (nonatomic, readonly) float paddingRight;
2955
- @property (nonatomic, readonly) float paddingBottom;
2956
- @property (nonatomic, readonly) float paddingLeft;
2957
- @property (nonatomic, readonly) float contentWidth;
2958
- @property (nonatomic, readonly) float contentHeight;
2959
- @property (nonatomic, readonly) float scrollbarWidth;
2960
- @property (nonatomic, readonly) float scrollbarHeight;
2961
- @property (nonatomic, readonly) BOOL sizeIsEmpty;
2962
- @property (nonatomic, readonly) BOOL paddingIsEmpty;
2963
- @property (nonatomic, readonly) BOOL marginIsEmpty;
2964
- @property (nonatomic, readonly) BOOL borderIsEmpty;
2965
- @property (nonatomic, readonly, strong) MasonRectHelper * _Nonnull border;
2966
- @property (nonatomic, readonly, strong) MasonRectHelper * _Nonnull margin;
2967
- @property (nonatomic, readonly, strong) MasonRectHelper * _Nonnull padding;
2968
- @property (nonatomic, readonly, strong) MasonSizeHelper * _Nonnull contentSize;
2969
- @property (nonatomic, readonly, strong) MasonSizeHelper * _Nonnull scrollbarSize;
2970
- @property (nonatomic, readonly) BOOL hasChildren;
2971
- @property (nonatomic, readonly, copy) NSArray<MasonLayout *> * _Nonnull children;
2972
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
2973
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
2974
- @end
2975
-
2976
- SWIFT_ENUM_FWD_DECL(NSInteger, MasonLengthPercentageAutoCompatType)
2977
- SWIFT_CLASS_NAMED("MasonLengthPercentageAutoCompat")
2978
- @interface MasonLengthPercentageAutoCompat : NSObject
2979
- - (nonnull instancetype)initWithPoints:(float)points OBJC_DESIGNATED_INITIALIZER;
2980
- - (nonnull instancetype)initWithPercent:(float)percent OBJC_DESIGNATED_INITIALIZER;
2981
- @property (nonatomic, readonly) enum MasonLengthPercentageAutoCompatType type;
2982
- @property (nonatomic, readonly) float value;
2983
- @property (nonatomic, readonly, copy) NSString * _Nonnull cssValue;
2984
- @property (nonatomic, readonly, copy) NSString * _Nullable jsonValue;
2985
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MasonLengthPercentageAutoCompat * _Nonnull Auto;)
2986
- + (MasonLengthPercentageAutoCompat * _Nonnull)Auto SWIFT_WARN_UNUSED_RESULT;
2987
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MasonLengthPercentageAutoCompat * _Nonnull Zero;)
2988
- + (MasonLengthPercentageAutoCompat * _Nonnull)Zero SWIFT_WARN_UNUSED_RESULT;
2989
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
2990
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
2991
- @end
2992
-
2993
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonLengthPercentageAutoCompatType, "MasonLengthPercentageAutoCompatType", open) {
2994
- MasonLengthPercentageAutoCompatTypeAuto = 0,
2995
- MasonLengthPercentageAutoCompatTypePoints = 1,
2996
- MasonLengthPercentageAutoCompatTypePercent = 2,
2997
- };
2998
-
2999
- SWIFT_CLASS_NAMED("MasonLengthPercentageAutoPointCompat")
3000
- @interface MasonLengthPercentageAutoPointCompat : NSObject
3001
- @property (nonatomic, strong) MasonLengthPercentageAutoCompat * _Nonnull x;
3002
- @property (nonatomic, strong) MasonLengthPercentageAutoCompat * _Nonnull y;
3003
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
3004
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
3005
- @end
3006
-
3007
- SWIFT_CLASS_NAMED("MasonLengthPercentageAutoRectCompat")
3008
- @interface MasonLengthPercentageAutoRectCompat : NSObject
3009
- @property (nonatomic, strong) MasonLengthPercentageAutoCompat * _Nonnull left;
3010
- @property (nonatomic, strong) MasonLengthPercentageAutoCompat * _Nonnull right;
3011
- @property (nonatomic, strong) MasonLengthPercentageAutoCompat * _Nonnull top;
3012
- @property (nonatomic, strong) MasonLengthPercentageAutoCompat * _Nonnull bottom;
3013
- - (nonnull instancetype)init:(MasonLengthPercentageAutoCompat * _Nonnull)left :(MasonLengthPercentageAutoCompat * _Nonnull)top :(MasonLengthPercentageAutoCompat * _Nonnull)right :(MasonLengthPercentageAutoCompat * _Nonnull)bottom OBJC_DESIGNATED_INITIALIZER;
3014
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
3015
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
3016
- @end
3017
-
3018
- SWIFT_CLASS_NAMED("MasonLengthPercentageAutoSizeCompat")
3019
- @interface MasonLengthPercentageAutoSizeCompat : NSObject
3020
- @property (nonatomic, strong) MasonLengthPercentageAutoCompat * _Nonnull width;
3021
- @property (nonatomic, strong) MasonLengthPercentageAutoCompat * _Nonnull height;
3022
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
3023
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
3024
- @end
3025
-
3026
- SWIFT_ENUM_FWD_DECL(NSInteger, MasonLengthPercentageCompatType)
3027
- SWIFT_CLASS_NAMED("MasonLengthPercentageCompat")
3028
- @interface MasonLengthPercentageCompat : NSObject
3029
- - (nonnull instancetype)initWithPoints:(float)points OBJC_DESIGNATED_INITIALIZER;
3030
- - (nonnull instancetype)initWithPercent:(float)percent OBJC_DESIGNATED_INITIALIZER;
3031
- @property (nonatomic, readonly) enum MasonLengthPercentageCompatType type;
3032
- @property (nonatomic, readonly) float value;
3033
- @property (nonatomic, readonly, copy) NSString * _Nonnull cssValue;
3034
- @property (nonatomic, readonly, copy) NSString * _Nullable jsonValue;
3035
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MasonLengthPercentageCompat * _Nonnull Zero;)
3036
- + (MasonLengthPercentageCompat * _Nonnull)Zero SWIFT_WARN_UNUSED_RESULT;
3037
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
3038
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
3039
- @end
3040
-
3041
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonLengthPercentageCompatType, "MasonLengthPercentageCompatType", open) {
3042
- MasonLengthPercentageCompatTypePoints = 0,
3043
- MasonLengthPercentageCompatTypePercent = 1,
3044
- };
3045
-
3046
- SWIFT_CLASS_NAMED("MasonLengthPercentagePointCompat")
3047
- @interface MasonLengthPercentagePointCompat : NSObject
3048
- @property (nonatomic, strong) MasonLengthPercentageCompat * _Nonnull x;
3049
- @property (nonatomic, strong) MasonLengthPercentageCompat * _Nonnull y;
3050
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
3051
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
3052
- @end
3053
-
3054
- SWIFT_CLASS_NAMED("MasonLengthPercentageRectCompat")
3055
- @interface MasonLengthPercentageRectCompat : NSObject
3056
- @property (nonatomic, strong) MasonLengthPercentageCompat * _Nonnull left;
3057
- @property (nonatomic, strong) MasonLengthPercentageCompat * _Nonnull right;
3058
- @property (nonatomic, strong) MasonLengthPercentageCompat * _Nonnull top;
3059
- @property (nonatomic, strong) MasonLengthPercentageCompat * _Nonnull bottom;
3060
- - (nonnull instancetype)init:(MasonLengthPercentageCompat * _Nonnull)left :(MasonLengthPercentageCompat * _Nonnull)right :(MasonLengthPercentageCompat * _Nonnull)top :(MasonLengthPercentageCompat * _Nonnull)bottom OBJC_DESIGNATED_INITIALIZER;
3061
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
3062
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
3063
- @end
3064
-
3065
- SWIFT_CLASS_NAMED("MasonLengthPercentageSizeCompat")
3066
- @interface MasonLengthPercentageSizeCompat : NSObject
3067
- @property (nonatomic, strong) MasonLengthPercentageCompat * _Nonnull width;
3068
- @property (nonatomic, strong) MasonLengthPercentageCompat * _Nonnull height;
3069
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
3070
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
3071
- @end
3072
-
3073
- SWIFT_CLASS_NAMED("MasonLi")
3074
- @interface MasonLi : UIView <MasonElementObjc>
3075
- - (void)requestLayout;
3076
- - (void)drawRect:(CGRect)rect;
3077
- @property (nonatomic, readonly, strong) MasonNode * _Nonnull node;
3078
- @property (nonatomic, readonly, strong) NSCMason * _Nonnull mason;
3079
- @property (nonatomic, readonly, strong) UIView * _Nonnull uiView;
3080
- @property (nonatomic, readonly, strong) MasonStyle * _Nonnull style;
3081
- @property (nonatomic) BOOL isOrdered;
3082
- - (void)layoutSubviews;
3083
- /// Reset view state for recycling
3084
- - (void)resetForRecycle;
3085
- /// Set marker value and position for this list item
3086
- - (void)bindWithPosition:(NSInteger)position isOrdered:(BOOL)isOrdered;
3087
- - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder SWIFT_UNAVAILABLE;
3088
- - (nonnull instancetype)initWithFrame:(CGRect)frame SWIFT_UNAVAILABLE;
3089
- @end
3090
-
3091
- @protocol MasonListDelegate;
3092
- @class UICollectionView;
3093
- @class NSIndexPath;
3094
- @class UICollectionViewCell;
3095
- SWIFT_CLASS_NAMED("MasonList")
3096
- @interface MasonList : UIView <MasonElementObjc, UICollectionViewDataSource, UICollectionViewDataSourcePrefetching, UICollectionViewDelegateFlowLayout>
3097
- @property (nonatomic, strong) id <MasonListDelegate> _Nullable delegate;
3098
- - (void)drawRect:(CGRect)rect;
3099
- @property (nonatomic, readonly, strong) MasonNode * _Nonnull node;
3100
- @property (nonatomic, readonly, strong) NSCMason * _Nonnull mason;
3101
- @property (nonatomic, readonly, strong) UIView * _Nonnull uiView;
3102
- @property (nonatomic, readonly, strong) MasonStyle * _Nonnull style;
3103
- /// Static items keyed by their position in the overall list.
3104
- /// Positions not in this dictionary are virtual (recycled via delegate).
3105
- @property (nonatomic, readonly, copy) NSDictionary<NSNumber *, MasonLi *> * _Nonnull staticItems;
3106
- /// Backward-compat: flat array of static views (unpositioned).
3107
- /// Setting this clears staticItems and assigns positions 0..<array.count.
3108
- @property (nonatomic, copy) NSArray<MasonLi *> * _Nonnull staticViews;
3109
- @property (nonatomic, strong) NSMutableData * _Nonnull values;
3110
- /// Virtual item count (set by user). Total count = staticItems.count + this value.
3111
- @property (nonatomic) NSInteger count;
3112
- - (void)layoutSubviews;
3113
- - (void)registerWithCellClass:(Class _Nullable)cellClass forCellWithReuseIdentifier:(NSString * _Nonnull)identifier;
3114
- /// Appends a static item at the end of the list (position = current count).
3115
- - (void)addView:(MasonLi * _Nonnull)item;
3116
- /// Inserts a static item at the given position, shifting existing entries at >= index.
3117
- - (void)addView:(MasonLi * _Nonnull)item at:(NSInteger)index;
3118
- - (void)reload;
3119
- @property (nonatomic) BOOL isOrdered;
3120
- - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder SWIFT_UNAVAILABLE;
3121
- - (void)invalidateSizeCache;
3122
- - (void)invalidateSizeCacheAt:(NSInteger)index;
3123
- - (void)collectionView:(UICollectionView * _Nonnull)collectionView prefetchItemsAtIndexPaths:(NSArray<NSIndexPath *> * _Nonnull)indexPaths;
3124
- - (NSInteger)collectionView:(UICollectionView * _Nonnull)collectionView numberOfItemsInSection:(NSInteger)section SWIFT_WARN_UNUSED_RESULT;
3125
- - (NSInteger)numberOfSectionsInCollectionView:(UICollectionView * _Nonnull)collectionView SWIFT_WARN_UNUSED_RESULT;
3126
- - (UICollectionViewCell * _Nonnull)collectionView:(UICollectionView * _Nonnull)collectionView cellForItemAtIndexPath:(NSIndexPath * _Nonnull)indexPath SWIFT_WARN_UNUSED_RESULT;
3127
- - (void)collectionView:(UICollectionView * _Nonnull)collectionView willDisplayCell:(UICollectionViewCell * _Nonnull)cell forItemAtIndexPath:(NSIndexPath * _Nonnull)indexPath;
3128
- - (nonnull instancetype)initWithFrame:(CGRect)frame SWIFT_UNAVAILABLE;
3129
- @end
3130
-
3131
- SWIFT_PROTOCOL_NAMED("MasonListDelegate")
3132
- @protocol MasonListDelegate
3133
- - (UICollectionViewCell * _Nonnull)list:(UICollectionView * _Nonnull)list cellForItemAt:(NSIndexPath * _Nonnull)indexPath SWIFT_WARN_UNUSED_RESULT;
3134
- - (void)list:(UICollectionView * _Nonnull)list willDisplay:(UICollectionViewCell * _Nonnull)cell forItemAt:(NSIndexPath * _Nonnull)indexPath;
3135
- @end
3136
-
3137
- @class UICollectionViewLayoutAttributes;
3138
- SWIFT_CLASS_NAMED("MasonListCell")
3139
- @interface MasonListCell : UICollectionViewCell
3140
- @property (nonatomic, copy) void (^ _Nullable willMove)(MasonListCell * _Nonnull);
3141
- + (MasonListCell * _Nonnull)initWithEmptyBackground SWIFT_METHOD_FAMILY(none) SWIFT_WARN_UNUSED_RESULT;
3142
- - (void)setViewWithCompat:(id <MasonElementObjc> _Nullable)view;
3143
- - (void)willMoveToSuperview:(UIView * _Nullable)newSuperview;
3144
- - (void)prepareForReuse;
3145
- - (UICollectionViewLayoutAttributes * _Nonnull)preferredLayoutAttributesFittingAttributes:(UICollectionViewLayoutAttributes * _Nonnull)layoutAttributes SWIFT_WARN_UNUSED_RESULT;
3146
- - (void)layoutSubviews;
3147
- - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
3148
- - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
3149
- @end
3150
-
3151
- @class MasonMouseEventOptions;
3152
- SWIFT_CLASS_NAMED("MasonMouseEvent")
3153
- @interface MasonMouseEvent : MasonEvent
3154
- @property (nonatomic, readonly) NSInteger button;
3155
- @property (nonatomic, readonly) NSInteger buttons;
3156
- @property (nonatomic, readonly) float clientX;
3157
- @property (nonatomic, readonly) float clientY;
3158
- @property (nonatomic, readonly) BOOL ctrlKey;
3159
- @property (nonatomic, readonly) BOOL shiftKey;
3160
- @property (nonatomic, readonly) BOOL altKey;
3161
- @property (nonatomic, readonly) BOOL metaKey;
3162
- @property (nonatomic, readonly) NSInteger detail;
3163
- @property (nonatomic, readonly) float screenX;
3164
- @property (nonatomic, readonly) float screenY;
3165
- @property (nonatomic, readonly) id _Nullable relatedTarget;
3166
- @property (nonatomic, readonly) id _Nullable region;
3167
- @property (nonatomic, readonly) NSInteger movementX;
3168
- @property (nonatomic, readonly) NSInteger movementY;
3169
- @property (nonatomic, readonly) float pageX;
3170
- @property (nonatomic, readonly) float pageY;
3171
- - (nonnull instancetype)initWithType:(NSString * _Nonnull)type options:(MasonMouseEventOptions * _Nullable)options OBJC_DESIGNATED_INITIALIZER;
3172
- - (nonnull instancetype)initWithType:(NSString * _Nonnull)eventType bubbles:(BOOL)eventBubbles cancelable:(BOOL)eventCancelable options:(MasonEventOptions * _Nullable)options SWIFT_UNAVAILABLE;
3173
- @end
3174
-
3175
- SWIFT_CLASS_NAMED("MasonMouseEventOptions")
3176
- @interface MasonMouseEventOptions : MasonEventOptions
3177
- - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
3178
- - (nonnull instancetype)initWithIsComposing:(BOOL)isComposing OBJC_DESIGNATED_INITIALIZER;
3179
- @end
3180
-
3181
- SWIFT_ENUM_FWD_DECL(uint16_t, PseudoState)
3182
- SWIFT_ENUM_FWD_DECL(int32_t, MasonNodeType)
3183
- SWIFT_CLASS_NAMED("MasonNode")
3184
- @interface MasonNode : NSObject
3185
- @property (nonatomic, readonly, strong) NSCMason * _Nonnull mason;
3186
- /// Attributes carried over from parsed HTML (<code>class</code>, <code>id</code>, <code>href</code>, <code>alt</code>,
3187
- /// <code>title</code>). Recorded, not acted on by the cascade — see applyAttributes in
3188
- /// HTMLParser for why.
3189
- @property (nonatomic, copy) NSDictionary<NSString *, NSString *> * _Nonnull htmlAttributes;
3190
- @property (nonatomic, copy) void (^ _Nullable onNodeAttached)(void);
3191
- @property (nonatomic, copy) void (^ _Nullable onNodeDetached)(void);
3192
- @property (nonatomic, readonly) void * _Nullable nativePtr;
3193
- @property (nonatomic, readonly, strong) MasonLayout * _Nonnull computedLayout;
3194
- /// Set to true by applyToView after Mason has applied layout to this node’s view.
3195
- /// NativeScript can read this to skip redundant layout passes for Mason-managed children.
3196
- @property (nonatomic) BOOL isLayoutValid;
3197
- @property (nonatomic, readonly, strong) MasonDocument * _Nullable document;
3198
- - (void)setPseudoString:(uint16_t)pseudoState :(NSString * _Nonnull)key :(NSString * _Nonnull)value;
3199
- - (NSString * _Nullable)getPseudoString:(uint16_t)pseudoState :(NSString * _Nonnull)key SWIFT_WARN_UNUSED_RESULT;
3200
- - (void)clearPseudoString:(uint16_t)pseudoState :(NSString * _Nonnull)key;
3201
- /// Current active pseudo state bitmask read from the native state buffer.
3202
- @property (nonatomic, readonly) uint16_t pseudoMask;
3203
- - (BOOL)hasPseudo:(enum PseudoState)state SWIFT_WARN_UNUSED_RESULT;
3204
- - (void)setPseudo:(enum PseudoState)state :(BOOL)enabled autoDirty:(BOOL)autoDirty;
3205
- /// Get existing pseudo style buffer (read-only).
3206
- - (NSMutableData * _Nullable)getPseudoBuffer:(uint16_t)flags SWIFT_WARN_UNUSED_RESULT;
3207
- /// Prepare (create if needed) a mutable pseudo style buffer.
3208
- /// Clones from base style on first call for a given state.
3209
- - (NSMutableData * _Nonnull)preparePseudoBuffer:(uint16_t)flags SWIFT_WARN_UNUSED_RESULT;
3210
- - (MasonNode * _Nonnull)getRootNode SWIFT_WARN_UNUSED_RESULT;
3211
- @property (nonatomic, readonly, strong) MasonNode * _Nullable parent;
3212
- @property (nonatomic, readonly, strong) MasonNode * _Nullable parentNode;
3213
- @property (nonatomic, readonly) enum MasonNodeType type;
3214
- - (NSArray<MasonNode *> * _Nonnull)getChildren SWIFT_WARN_UNUSED_RESULT;
3215
- - (NSArray<MasonNode *> * _Nonnull)getLayoutChildren SWIFT_WARN_UNUSED_RESULT;
3216
- @property (nonatomic) BOOL inBatch;
3217
- - (nonnull instancetype)initWithMason:(NSCMason * _Nonnull)doc children:(NSArray<MasonNode *> * _Nonnull)nodes OBJC_DESIGNATED_INITIALIZER;
3218
- @property (nonatomic, readonly) BOOL isDirty;
3219
- - (void)markDirty;
3220
- - (UIView * _Nullable)getRoot SWIFT_WARN_UNUSED_RESULT;
3221
- /// Helper to get default text attributes for new text nodes
3222
- - (NSDictionary<NSAttributedStringKey, id> * _Nonnull)getDefaultAttributes SWIFT_WARN_UNUSED_RESULT;
3223
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
3224
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
3225
- @end
3226
-
3227
- @interface MasonNode (SWIFT_EXTENSION(Mason))
3228
- - (void)setChildrenWithValue:(NSArray<MasonNode *> * _Nonnull)value;
3229
- - (void)appendChild:(MasonNode * _Nonnull)child;
3230
- - (void)removeAllChildren;
3231
- @end
3232
-
3233
- typedef SWIFT_ENUM_NAMED(int32_t, MasonNodeType, "MasonNodeType", open) {
3234
- MasonNodeTypeElement = 0,
3235
- MasonNodeTypeText = 1,
3236
- MasonNodeTypeDocument = 2,
3237
- };
3238
-
3239
- SWIFT_ENUM_FWD_DECL(NSInteger, MasonOverflow)
3240
- SWIFT_CLASS_NAMED("MasonOverflowPointCompat")
3241
- @interface MasonOverflowPointCompat : NSObject
3242
- @property (nonatomic) enum MasonOverflow x;
3243
- @property (nonatomic) enum MasonOverflow y;
3244
- @property (nonatomic, readonly, copy) NSString * _Nonnull cssValue;
3245
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
3246
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
3247
- @end
3248
-
3249
- SWIFT_CLASS_NAMED("MasonRectHelper")
3250
- @interface MasonRectHelper : NSObject
3251
- @property (nonatomic, readonly) float top;
3252
- @property (nonatomic, readonly) float right;
3253
- @property (nonatomic, readonly) float bottom;
3254
- @property (nonatomic, readonly) float left;
3255
- - (BOOL)isEmpty SWIFT_WARN_UNUSED_RESULT;
3256
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
3257
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
3258
- @end
3259
-
3260
- SWIFT_CLASS_NAMED("MasonSizeHelper")
3261
- @interface MasonSizeHelper : NSObject
3262
- @property (nonatomic, readonly) float width;
3263
- @property (nonatomic, readonly) float height;
3264
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
3265
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
3266
- @end
3267
-
3268
- @class NSCFontFace;
3269
- @class MasonVerticalAlignValue;
3270
- SWIFT_ENUM_FWD_DECL(NSInteger, MasonObjectFit)
3271
- @class UIColor;
3272
- SWIFT_ENUM_FWD_DECL(NSInteger, MasonTextJustify)
3273
- @class MasonTextOverflowCompat;
3274
- SWIFT_ENUM_FWD_DECL(NSInteger, MasonTextTransform)
3275
- SWIFT_ENUM_FWD_DECL(NSInteger, MasonWhiteSpace)
3276
- SWIFT_ENUM_FWD_DECL(NSInteger, MasonTextWrap)
3277
- SWIFT_ENUM_FWD_DECL(NSInteger, MasonPosition)
3278
- SWIFT_ENUM_FWD_DECL(NSInteger, MasonTextAlign)
3279
- SWIFT_CLASS_NAMED("MasonStyle")
3280
- @interface MasonStyle : NSObject
3281
- @property (nonatomic, readonly, strong) NSCFontFace * _Null_unspecified font;
3282
- - (void)prepareMut;
3283
- @property (nonatomic, readonly, strong) NSMutableData * _Nonnull values;
3284
- - (nonnull instancetype)initWithNode:(MasonNode * _Nonnull)node OBJC_DESIGNATED_INITIALIZER;
3285
- @property (nonatomic) enum MasonListStylePosition listStylePosition;
3286
- @property (nonatomic) enum MasonListStyleType listStyleType;
3287
- @property (nonatomic) int32_t zIndex;
3288
- @property (nonatomic, strong) MasonVerticalAlignValue * _Nonnull verticalAlign;
3289
- @property (nonatomic) enum MasonObjectFit objectFit;
3290
- @property (nonatomic, getter=float, setter=setFloat:) enum MasonFloat float_;
3291
- @property (nonatomic) enum MasonClear clear;
3292
- @property (nonatomic) uint32_t color;
3293
- - (void)setColorWithUi:(UIColor * _Nonnull)color;
3294
- - (void)setColorWithCss:(NSString * _Nonnull)color;
3295
- @property (nonatomic, copy) NSString * _Nonnull filter;
3296
- @property (nonatomic, copy) NSString * _Nonnull background;
3297
- @property (nonatomic, copy) NSString * _Nonnull backgroundImage;
3298
- @property (nonatomic, copy) NSString * _Nonnull backgroundRepeat;
3299
- @property (nonatomic, copy) NSString * _Nonnull backgroundPosition;
3300
- @property (nonatomic, copy) NSString * _Nonnull backgroundSize;
3301
- @property (nonatomic, copy) NSString * _Nonnull backgroundClip;
3302
- @property (nonatomic) uint32_t backgroundColor;
3303
- - (NSString * _Nonnull)getBackgroundColor SWIFT_WARN_UNUSED_RESULT;
3304
- - (void)setBackgroundColorWithString:(NSString * _Nonnull)color;
3305
- - (void)setBackgroundColorWithUi:(UIColor * _Nonnull)color;
3306
- - (void)setLineHeight:(float)value :(BOOL)isRelative;
3307
- @property (nonatomic) float lineHeight;
3308
- @property (nonatomic) float letterSpacing;
3309
- @property (nonatomic, copy) NSString * _Nonnull fontVariantNumericString;
3310
- @property (nonatomic) uint32_t decorationColor;
3311
- - (void)setDecorationColorWithUi:(UIColor * _Nonnull)color;
3312
- - (void)setDecorationColorWithCss:(NSString * _Nonnull)color;
3313
- @property (nonatomic) enum MasonDecorationLine decorationLine;
3314
- - (void)setTextDecoration:(NSString * _Nonnull)css;
3315
- - (void)setBorderColor:(NSString * _Nonnull)css;
3316
- - (void)applyListStyleType:(NSString * _Nonnull)css;
3317
- - (void)applyListStylePosition:(NSString * _Nonnull)css;
3318
- @property (nonatomic) int32_t fontSize;
3319
- - (void)setFontStyle:(enum MasonFontStyle)style :(int32_t)slant;
3320
- @property (nonatomic) enum MasonTextJustify textJustify;
3321
- @property (nonatomic) enum MasonFontStyle fontStyle;
3322
- @property (nonatomic, copy) NSString * _Nonnull fontFamily;
3323
- @property (nonatomic, copy) NSString * _Nonnull fontWeight;
3324
- @property (nonatomic, strong) MasonTextOverflowCompat * _Nonnull textOverflowCompat;
3325
- @property (nonatomic) enum MasonTextTransform textTransform;
3326
- @property (nonatomic) enum MasonWhiteSpace whiteSpace;
3327
- @property (nonatomic) enum MasonTextWrap textWrap;
3328
- @property (nonatomic) enum MasonDisplay display;
3329
- @property (nonatomic) enum MasonPosition position;
3330
- @property (nonatomic) enum MasonDirection direction;
3331
- @property (nonatomic) enum MasonFlexDirection flexDirection;
3332
- @property (nonatomic) enum MasonFlexWrap flexWrap;
3333
- @property (nonatomic, strong) MasonOverflowPointCompat * _Nonnull overflowCompat;
3334
- @property (nonatomic) enum MasonOverflow overflowX;
3335
- @property (nonatomic) enum MasonOverflow overflowY;
3336
- @property (nonatomic) enum MasonAlignItems alignItems;
3337
- @property (nonatomic) enum MasonAlignSelf alignSelf;
3338
- @property (nonatomic) enum MasonAlignContent alignContent;
3339
- @property (nonatomic) enum MasonJustifyItems justifyItems;
3340
- @property (nonatomic) enum MasonJustifySelf justifySelf;
3341
- @property (nonatomic) enum MasonJustifyContent justifyContent;
3342
- @property (nonatomic, strong) MasonLengthPercentageAutoRectCompat * _Nonnull insetCompat;
3343
- - (void)setInsetLeft:(float)value :(NSInteger)type;
3344
- - (void)setInsetRight:(float)value :(NSInteger)type;
3345
- - (void)setInsetTop:(float)value :(NSInteger)type;
3346
- - (void)setInsetBottom:(float)value :(NSInteger)type;
3347
- - (void)setInsetWithValueType:(float)value :(NSInteger)type;
3348
- @property (nonatomic, strong) MasonLengthPercentageAutoRectCompat * _Nonnull marginCompat;
3349
- - (void)setMarginLeft:(float)value :(NSInteger)type;
3350
- - (void)setMarginRight:(float)value :(NSInteger)type;
3351
- - (void)setMarginTop:(float)value :(NSInteger)type;
3352
- - (void)setMarginBottom:(float)value :(NSInteger)type;
3353
- - (void)setMarginWithValueType:(float)value :(NSInteger)type;
3354
- @property (nonatomic, strong) MasonLengthPercentageRectCompat * _Nonnull paddingCompat;
3355
- - (void)setPaddingLeft:(float)value :(NSInteger)type;
3356
- - (void)setPaddingRight:(float)value :(NSInteger)type;
3357
- - (void)setPaddingTop:(float)value :(NSInteger)type;
3358
- - (void)setPaddingBottom:(float)value :(NSInteger)type;
3359
- - (void)setPaddingWithValueType:(float)value :(NSInteger)type;
3360
- @property (nonatomic, copy) NSString * _Nonnull textShadow;
3361
- @property (nonatomic, copy) NSString * _Nonnull boxShadow;
3362
- @property (nonatomic, copy) NSString * _Nonnull borderRadius;
3363
- @property (nonatomic, copy) NSString * _Nonnull cornerShape;
3364
- @property (nonatomic, copy) NSString * _Nonnull cornerShapeTopLeft;
3365
- @property (nonatomic, copy) NSString * _Nonnull cornerShapeTopRight;
3366
- @property (nonatomic, copy) NSString * _Nonnull cornerShapeBottomRight;
3367
- @property (nonatomic, copy) NSString * _Nonnull cornerShapeBottomLeft;
3368
- @property (nonatomic, copy) NSString * _Nonnull border;
3369
- @property (nonatomic, copy) NSString * _Nonnull paddingCss;
3370
- @property (nonatomic, copy) NSString * _Nonnull marginCss;
3371
- @property (nonatomic, copy) NSString * _Nonnull insetCss;
3372
- @property (nonatomic, copy) NSString * _Nonnull borderLeft;
3373
- @property (nonatomic, copy) NSString * _Nonnull borderTop;
3374
- @property (nonatomic, copy) NSString * _Nonnull borderRight;
3375
- @property (nonatomic, copy) NSString * _Nonnull borderBottom;
3376
- @property (nonatomic, strong) MasonLengthPercentageRectCompat * _Nonnull borderWidthCompat;
3377
- - (void)setBorderLeftWidth:(float)value :(NSInteger)type;
3378
- - (void)setBorderRightWidth:(float)value :(NSInteger)type;
3379
- - (void)setBorderTopWidth:(float)value :(NSInteger)type;
3380
- - (void)setBorderBottomWidth:(float)value :(NSInteger)type;
3381
- - (void)setBorderWidth:(float)value :(NSInteger)type;
3382
- @property (nonatomic) float flexGrow;
3383
- @property (nonatomic) float flexShrink;
3384
- - (void)setFlexBasis:(float)value :(NSInteger)type;
3385
- - (void)setScrollBarWidth:(float)value;
3386
- @property (nonatomic) enum MasonAlign align;
3387
- @property (nonatomic) enum MasonTextAlign textAlign;
3388
- @property (nonatomic) enum MasonBoxSizing boxSizing;
3389
- @property (nonatomic, strong) MasonDimensionSizeCompat * _Nonnull minSizeCompat;
3390
- - (void)setMinSizeWidth:(float)value :(NSInteger)type;
3391
- - (void)setMinSizeHeight:(float)value :(NSInteger)type;
3392
- - (void)setMinSizeWidthHeight:(float)value :(NSInteger)type;
3393
- @property (nonatomic, strong) MasonDimensionSizeCompat * _Nonnull sizeCompat;
3394
- @property (nonatomic, strong) MasonDimensionCompat * _Nonnull sizeCompatWidth;
3395
- @property (nonatomic, strong) MasonDimensionCompat * _Nonnull sizeCompatHeight;
3396
- - (void)setSizeWidth:(float)value :(NSInteger)type;
3397
- - (void)setSizeHeight:(float)value :(NSInteger)type;
3398
- - (void)setSizeWidthHeight:(float)value :(NSInteger)type;
3399
- - (void)setSizePoints:(float)width :(float)height;
3400
- @property (nonatomic, strong) MasonDimensionSizeCompat * _Nonnull maxSizeCompat;
3401
- - (void)setMaxSizeWidth:(float)value :(NSInteger)type;
3402
- - (void)setMaxSizeHeight:(float)value :(NSInteger)type;
3403
- - (void)setMaxSizeWidthHeight:(float)value :(NSInteger)type;
3404
- @property (nonatomic, strong) MasonLengthPercentageSizeCompat * _Nonnull gapCompat;
3405
- - (void)setGapRow:(float)value :(NSInteger)type;
3406
- - (void)setGapColumn:(float)value :(NSInteger)type;
3407
- - (void)setRowGap:(float)value :(NSInteger)type;
3408
- - (void)setColumnGap:(float)value :(NSInteger)type;
3409
- @property (nonatomic, copy) NSString * _Nonnull gridArea;
3410
- @property (nonatomic, copy) NSString * _Nonnull gridTemplateAreas;
3411
- @property (nonatomic, copy) NSString * _Nonnull transform;
3412
- @property (nonatomic, copy) NSString * _Nonnull gridAutoRows;
3413
- @property (nonatomic, copy) NSString * _Nonnull gridAutoColumns;
3414
- @property (nonatomic) enum MasonGridAutoFlowWrap gridAutoFlow;
3415
- @property (nonatomic, copy) NSString * _Nonnull gridColumn;
3416
- @property (nonatomic, copy) NSString * _Nonnull gridColumnStart;
3417
- @property (nonatomic, copy) NSString * _Nonnull gridColumnEnd;
3418
- @property (nonatomic, copy) NSString * _Nonnull gridRow;
3419
- @property (nonatomic, copy) NSString * _Nonnull gridRowStart;
3420
- @property (nonatomic, copy) NSString * _Nonnull gridRowEnd;
3421
- @property (nonatomic, copy) NSString * _Nonnull gridTemplateRows;
3422
- @property (nonatomic, copy) NSString * _Nonnull gridTemplateColumns;
3423
- @property (nonatomic, copy) NSString * _Nonnull borderImage;
3424
- @property (nonatomic, copy) NSString * _Nonnull backdropFilter;
3425
- @property (nonatomic, copy) NSString * _Nonnull fontFeatureSettings;
3426
- - (void)updateNativeStyle;
3427
- @property (nonatomic, readonly, copy) NSString * _Nonnull description;
3428
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
3429
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
3430
- @end
3431
-
3432
- SWIFT_ENUM_FWD_DECL(NSInteger, MasonTextType)
3433
- SWIFT_CLASS_NAMED("MasonText")
3434
- @interface MasonText : UIView <MasonElementObjc, MasonTextContainer>
3435
- @property (nonatomic, readonly, strong) MasonNode * _Nonnull node;
3436
- @property (nonatomic, readonly) enum MasonTextType type;
3437
- @property (nonatomic, strong) MasonTextEngine * _Nonnull engine;
3438
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly) Class _Nonnull layerClass;)
3439
- + (Class _Nonnull)layerClass SWIFT_WARN_UNUSED_RESULT;
3440
- @property (nonatomic, readonly, strong) NSMutableData * _Nonnull textValues;
3441
- - (void)onStyleChange:(uint64_t)low :(uint64_t)high;
3442
- @property (nonatomic, readonly, strong) UIView * _Nonnull uiView;
3443
- @property (nonatomic, readonly, strong) MasonStyle * _Nonnull style;
3444
- - (nonnull instancetype)initWithMason:(NSCMason * _Nonnull)mason type:(enum MasonTextType)textType OBJC_DESIGNATED_INITIALIZER;
3445
- - (nonnull instancetype)initWithMason:(NSCMason * _Nonnull)mason OBJC_DESIGNATED_INITIALIZER;
3446
- - (void)setNeedsDisplay;
3447
- - (void)didMoveToWindow;
3448
- - (void)requestLayout;
3449
- - (void)layoutSubviews;
3450
- - (void)addView:(UIView * _Nonnull)view;
3451
- - (void)addView:(UIView * _Nonnull)view at:(NSInteger)at;
3452
- - (void)removeView:(UIView * _Nonnull)view;
3453
- - (void)removeViewAt:(NSInteger)index;
3454
- - (void)removeAllViews;
3455
- - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder SWIFT_UNAVAILABLE;
3456
- @property (nonatomic, strong) MasonTextOverflowCompat * _Nonnull textOverflowCompat;
3457
- @property (nonatomic) uint32_t color;
3458
- - (void)setColorWithUi:(UIColor * _Nonnull)color;
3459
- @property (nonatomic) uint32_t backgroundColorValue;
3460
- - (void)setBackgroundColorWithUi:(UIColor * _Nonnull)color;
3461
- @property (nonatomic) uint32_t decorationColor;
3462
- - (void)setDecorationColorWithUi:(UIColor * _Nonnull)color;
3463
- @property (nonatomic) enum MasonDecorationLine decorationLine;
3464
- @property (nonatomic) int32_t fontSize;
3465
- @property (nonatomic) enum MasonFontStyle fontStyle;
3466
- - (void)setFontStyle:(enum MasonFontStyle)style slant:(int32_t)slant;
3467
- @property (nonatomic, copy) NSString * _Nonnull fontWeight;
3468
- @property (nonatomic) enum MasonTextTransform textTransform;
3469
- @property (nonatomic) enum MasonWhiteSpace whiteSpace;
3470
- @property (nonatomic) enum MasonTextWrap textWrap;
3471
- @property (nonatomic) float lineHeight;
3472
- /// Text content - sets or gets the concatenated text from all text nodes
3473
- @property (nonatomic, copy) NSString * _Nonnull textContent;
3474
- - (nonnull instancetype)initWithFrame:(CGRect)frame SWIFT_UNAVAILABLE;
3475
- @end
3476
-
3477
- @interface MasonText (SWIFT_EXTENSION(Mason))
3478
- - (void)addChild:(MasonNode * _Nonnull)child;
3479
- @end
3480
-
3481
- @interface MasonText (SWIFT_EXTENSION(Mason))
3482
- /// Remove child from text container
3483
- - (MasonNode * _Nullable)removeChild:(MasonNode * _Nonnull)child;
3484
- @end
3485
-
3486
- @class NSTextContainer;
3487
- @class NSAttributedString;
3488
- @class UIFont;
3489
- @class UITextPosition;
3490
- SWIFT_CLASS_NAMED("MasonTextInput")
3491
- @interface MasonTextInput : UITextView <UITextViewDelegate>
3492
- - (nonnull instancetype)initWithFrame:(CGRect)frame textContainer:(NSTextContainer * _Nullable)textContainer SWIFT_UNAVAILABLE;
3493
- - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder SWIFT_UNAVAILABLE;
3494
- @property (nonatomic, copy) NSString * _Nullable placeholder;
3495
- @property (nonatomic, copy) NSString * _Null_unspecified text;
3496
- @property (nonatomic, strong) NSAttributedString * _Null_unspecified attributedText;
3497
- @property (nonatomic, strong) UIFont * _Nullable font;
3498
- @property (nonatomic) NSTextAlignment textAlignment;
3499
- - (void)layoutSubviews;
3500
- - (void)textViewDidChange:(UITextView * _Nonnull)textView;
3501
- - (void)textViewDidBeginEditing:(UITextView * _Nonnull)textView;
3502
- - (void)textViewDidEndEditing:(UITextView * _Nonnull)textView;
3503
- - (void)paste:(id _Nullable)sender;
3504
- - (void)cut:(id _Nullable)sender;
3505
- - (BOOL)textView:(UITextView * _Nonnull)textView shouldChangeTextInRange:(NSRange)range replacementText:(NSString * _Nonnull)text SWIFT_WARN_UNUSED_RESULT;
3506
- - (CGRect)caretRectForPosition:(UITextPosition * _Nonnull)position SWIFT_WARN_UNUSED_RESULT;
3507
- @end
3508
-
3509
- SWIFT_CLASS_NAMED("MasonTextArea")
3510
- @interface MasonTextArea : MasonTextInput <MasonElementObjc>
3511
- @property (nonatomic, readonly, strong) MasonNode * _Nonnull node;
3512
- @property (nonatomic, readonly, strong) NSCMason * _Nonnull mason;
3513
- @property (nonatomic, readonly, strong) UIView * _Nonnull uiView;
3514
- @property (nonatomic, readonly, strong) MasonStyle * _Nonnull style;
3515
- @property (nonatomic) NSInteger rows;
3516
- @property (nonatomic) NSInteger cols;
3517
- @property (nonatomic, copy) NSString * _Nonnull name;
3518
- @property (nonatomic) NSInteger maxLength;
3519
- @property (nonatomic, copy) NSString * _Nonnull value;
3520
- - (nonnull instancetype)initWithMason:(NSCMason * _Nonnull)doc OBJC_DESIGNATED_INITIALIZER;
3521
- - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
3522
- - (void)drawRect:(CGRect)rect;
3523
- - (void)layoutSubviews;
3524
- - (void)textViewDidChange:(UITextView * _Nonnull)textView;
3525
- - (void)onStyleChange:(uint64_t)low :(uint64_t)high;
3526
- - (BOOL)textView:(UITextView * _Nonnull)textView shouldChangeTextInRange:(NSRange)range replacementText:(NSString * _Nonnull)text SWIFT_WARN_UNUSED_RESULT;
3527
- @end
3528
-
3529
- SWIFT_CLASS("_TtC5Mason14MasonTextLayer")
3530
- @interface MasonTextLayer : CALayer
3531
- - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
3532
- - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder SWIFT_UNAVAILABLE;
3533
- - (nonnull instancetype)initWithLayer:(id _Nonnull)layer OBJC_DESIGNATED_INITIALIZER;
3534
- - (void)drawInContext:(CGContextRef _Nonnull)context;
3535
- @end
3536
-
3537
- SWIFT_CLASS_NAMED("MasonTextNode")
3538
- @interface MasonTextNode : MasonNode <MasonCharacterData>
3539
- @property (nonatomic, copy) NSString * _Nonnull data;
3540
- - (nonnull instancetype)initWithMason:(NSCMason * _Nonnull)doc data:(NSString * _Nonnull)text attributes:(NSDictionary<NSAttributedStringKey, id> * _Nullable)attrs OBJC_DESIGNATED_INITIALIZER;
3541
- - (void)appendChild:(MasonNode * _Nonnull)child;
3542
- @property (nonatomic, readonly) NSInteger length;
3543
- - (NSString * _Nonnull)substringDataWithOffset:(NSInteger)offset count:(NSInteger)count SWIFT_WARN_UNUSED_RESULT;
3544
- - (nonnull instancetype)appendData:(NSString * _Nonnull)s;
3545
- - (nonnull instancetype)insertData:(NSString * _Nonnull)s at:(NSInteger)offset;
3546
- - (nonnull instancetype)deleteDataWithOffset:(NSInteger)offset count:(NSInteger)count;
3547
- - (nonnull instancetype)replaceDataWithOffset:(NSInteger)offset count:(NSInteger)count with:(NSString * _Nonnull)s;
3548
- - (nonnull instancetype)deleteDataWithRange:(NSRange)range;
3549
- - (nonnull instancetype)replaceDataWithRange:(NSRange)range with:(NSString * _Nonnull)s;
3550
- - (nonnull instancetype)initWithMason:(NSCMason * _Nonnull)doc children:(NSArray<MasonNode *> * _Nonnull)nodes SWIFT_UNAVAILABLE;
3551
- @end
3552
-
3553
- @interface MasonTextNode (SWIFT_EXTENSION(Mason))
3554
- /// Get attributed string representation of this text node
3555
- - (NSAttributedString * _Nonnull)attributed SWIFT_WARN_UNUSED_RESULT;
3556
- @end
3557
-
3558
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonTextType, "MasonTextType", open) {
3559
- MasonTextTypeNone = 0,
3560
- MasonTextTypeP = 1,
3561
- MasonTextTypeSpan = 2,
3562
- MasonTextTypeCode = 3,
3563
- MasonTextTypeH1 = 4,
3564
- MasonTextTypeH2 = 5,
3565
- MasonTextTypeH3 = 6,
3566
- MasonTextTypeH4 = 7,
3567
- MasonTextTypeH5 = 8,
3568
- MasonTextTypeH6 = 9,
3569
- MasonTextTypeLi = 10,
3570
- MasonTextTypeBlockquote = 11,
3571
- MasonTextTypeB = 12,
3572
- MasonTextTypePre = 13,
3573
- MasonTextTypeStrong = 14,
3574
- MasonTextTypeEm = 15,
3575
- MasonTextTypeI = 16,
3576
- MasonTextTypeA = 17,
3577
- };
3578
-
3579
- SWIFT_CLASS_NAMED("MasonUIView")
3580
- @interface MasonUIView : UIView <MasonElementObjc>
3581
- - (void)drawRect:(CGRect)rect;
3582
- @property (nonatomic, readonly, strong) MasonNode * _Nonnull node;
3583
- @property (nonatomic, readonly, strong) NSCMason * _Nonnull mason;
3584
- @property (nonatomic, readonly, strong) UIView * _Nonnull uiView;
3585
- @property (nonatomic) CGSize contentSize;
3586
- @property (nonatomic) BOOL isScrollContainer;
3587
- @property (nonatomic) CGPoint contentOffset;
3588
- @property (nonatomic, readonly, strong) MasonStyle * _Nonnull style;
3589
- - (void)markNodeDirty;
3590
- - (BOOL)isNodeDirty SWIFT_WARN_UNUSED_RESULT;
3591
- - (void)layoutSubviews;
3592
- - (void)willMoveToWindow:(UIWindow * _Nullable)newWindow;
3593
- - (void)willMoveToSuperview:(UIView * _Nullable)newSuperview;
3594
- - (void)didMoveToSuperview;
3595
- - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder SWIFT_UNAVAILABLE;
3596
- + (MasonUIView * _Nonnull)createGridView:(NSCMason * _Nonnull)mason SWIFT_WARN_UNUSED_RESULT;
3597
- + (MasonUIView * _Nonnull)createFlexView:(NSCMason * _Nonnull)mason SWIFT_WARN_UNUSED_RESULT;
3598
- + (MasonUIView * _Nonnull)createBlockView:(NSCMason * _Nonnull)mason SWIFT_WARN_UNUSED_RESULT;
3599
- - (void)addView:(UIView * _Nonnull)view;
3600
- - (void)addView:(UIView * _Nonnull)view at:(NSInteger)at;
3601
- - (void)removeView:(UIView * _Nonnull)view;
3602
- - (void)removeViewAt:(NSInteger)index;
3603
- - (void)addSubviews:(NSArray<UIView *> * _Nonnull)views;
3604
- - (void)addSubviews:(NSArray<UIView *> * _Nonnull)views at:(NSInteger)index;
3605
- @property (nonatomic) BOOL inBatch;
3606
- @property (nonatomic, copy) NSString * _Nonnull background;
3607
- @property (nonatomic) enum MasonDisplay display;
3608
- @property (nonatomic) enum MasonPosition _position;
3609
- @property (nonatomic) enum MasonDirection direction;
3610
- @property (nonatomic) enum MasonFlexDirection flexDirection;
3611
- @property (nonatomic) enum MasonFlexWrap flexWrap;
3612
- @property (nonatomic) enum MasonOverflow overflowX;
3613
- @property (nonatomic) enum MasonOverflow overflowY;
3614
- @property (nonatomic) enum MasonAlignItems alignItems;
3615
- @property (nonatomic) enum MasonAlignSelf alignSelf;
3616
- @property (nonatomic) enum MasonAlignContent alignContent;
3617
- @property (nonatomic) enum MasonJustifyItems justifyItems;
3618
- @property (nonatomic) enum MasonJustifySelf justifySelf;
3619
- @property (nonatomic) enum MasonJustifyContent justifyContent;
3620
- @property (nonatomic) float flexGrow;
3621
- @property (nonatomic) float flexShrink;
3622
- @property (nonatomic, strong) MasonDimensionCompat * _Nonnull scrollBarWidthCompat;
3623
- @property (nonatomic, strong) MasonDimensionCompat * _Nonnull flexBasisCompat;
3624
- @property (nonatomic) float aspectRatio;
3625
- @property (nonatomic, copy) NSString * _Nonnull gridArea;
3626
- @property (nonatomic, copy) NSString * _Nonnull gridTemplateAreas;
3627
- @property (nonatomic, copy) NSString * _Nonnull gridAutoRows;
3628
- @property (nonatomic, copy) NSString * _Nonnull gridAutoColumns;
3629
- @property (nonatomic) enum MasonGridAutoFlowWrap gridAutoFlow;
3630
- @property (nonatomic, copy) NSString * _Nonnull gridColumn;
3631
- @property (nonatomic, copy) NSString * _Nonnull gridColumnStart;
3632
- @property (nonatomic, copy) NSString * _Nonnull gridColumnEnd;
3633
- @property (nonatomic, copy) NSString * _Nonnull gridRow;
3634
- @property (nonatomic, copy) NSString * _Nonnull gridRowStart;
3635
- @property (nonatomic, copy) NSString * _Nonnull gridRowEnd;
3636
- @property (nonatomic, copy) NSString * _Nonnull gridTemplateRows;
3637
- @property (nonatomic, copy) NSString * _Nonnull gridTemplateColumns;
3638
- - (void)setPadding:(float)left :(float)top :(float)right :(float)bottom;
3639
- - (MasonLengthPercentageRectCompat * _Nonnull)getPadding SWIFT_WARN_UNUSED_RESULT;
3640
- - (void)setPaddingLeft:(float)left :(NSInteger)type;
3641
- - (void)setPaddingRight:(float)right :(NSInteger)type;
3642
- - (void)setPaddingTop:(float)top :(NSInteger)type;
3643
- - (void)setPaddingBottom:(float)bottom :(NSInteger)type;
3644
- - (MasonLengthPercentageCompat * _Nonnull)getPaddingLeft SWIFT_WARN_UNUSED_RESULT;
3645
- - (MasonLengthPercentageCompat * _Nonnull)getPaddingRight SWIFT_WARN_UNUSED_RESULT;
3646
- - (MasonLengthPercentageCompat * _Nonnull)getPaddingTop SWIFT_WARN_UNUSED_RESULT;
3647
- - (MasonLengthPercentageCompat * _Nonnull)getPaddingBottom SWIFT_WARN_UNUSED_RESULT;
3648
- - (void)setBorderWidth:(float)left :(float)top :(float)right :(float)bottom;
3649
- - (MasonLengthPercentageRectCompat * _Nonnull)getBorderWidth SWIFT_WARN_UNUSED_RESULT;
3650
- - (void)setBorderLeftWidth:(float)left :(NSInteger)type;
3651
- - (void)setBorderRightWidth:(float)right :(NSInteger)type;
3652
- - (void)setBorderTopWidth:(float)top :(NSInteger)type;
3653
- - (void)setBorderBottomWidth:(float)bottom :(NSInteger)type;
3654
- - (MasonLengthPercentageCompat * _Nonnull)getBorderLeft SWIFT_WARN_UNUSED_RESULT;
3655
- - (MasonLengthPercentageCompat * _Nonnull)getBorderRight SWIFT_WARN_UNUSED_RESULT;
3656
- - (MasonLengthPercentageCompat * _Nonnull)getBorderBottom SWIFT_WARN_UNUSED_RESULT;
3657
- - (MasonLengthPercentageCompat * _Nonnull)getBorderTop SWIFT_WARN_UNUSED_RESULT;
3658
- - (void)setMargin:(float)left :(float)top :(float)right :(float)bottom;
3659
- - (MasonLengthPercentageAutoRectCompat * _Nonnull)getMargin SWIFT_WARN_UNUSED_RESULT;
3660
- - (void)setMarginLeft:(float)left :(NSInteger)type;
3661
- - (void)setMarginRight:(float)right :(NSInteger)type;
3662
- - (void)setMarginTop:(float)top :(NSInteger)type;
3663
- - (void)setMarginBottom:(float)bottom :(NSInteger)type;
3664
- - (MasonLengthPercentageAutoCompat * _Nonnull)getMarginLeft SWIFT_WARN_UNUSED_RESULT;
3665
- - (MasonLengthPercentageAutoCompat * _Nonnull)getMarginRight SWIFT_WARN_UNUSED_RESULT;
3666
- - (MasonLengthPercentageAutoCompat * _Nonnull)getMarginTop SWIFT_WARN_UNUSED_RESULT;
3667
- - (MasonLengthPercentageAutoCompat * _Nonnull)getMarginBottom SWIFT_WARN_UNUSED_RESULT;
3668
- - (void)setInset:(float)left :(float)top :(float)right :(float)bottom;
3669
- - (MasonLengthPercentageAutoRectCompat * _Nonnull)getInset SWIFT_WARN_UNUSED_RESULT;
3670
- - (void)setInsetLeft:(float)left :(NSInteger)type;
3671
- - (void)setInsetRight:(float)right :(NSInteger)type;
3672
- - (void)setInsetTop:(float)top :(NSInteger)type;
3673
- - (void)setInsetBottom:(float)bottom :(NSInteger)type;
3674
- - (MasonLengthPercentageAutoCompat * _Nonnull)getInsetLeft SWIFT_WARN_UNUSED_RESULT;
3675
- - (MasonLengthPercentageAutoCompat * _Nonnull)getInsetRight SWIFT_WARN_UNUSED_RESULT;
3676
- - (MasonLengthPercentageAutoCompat * _Nonnull)getInsetTop SWIFT_WARN_UNUSED_RESULT;
3677
- - (MasonLengthPercentageAutoCompat * _Nonnull)getInsetBottom SWIFT_WARN_UNUSED_RESULT;
3678
- - (void)setMinSize:(float)width :(float)height;
3679
- - (MasonDimensionSizeCompat * _Nonnull)getMinSize SWIFT_WARN_UNUSED_RESULT;
3680
- - (void)setMinSizeWidth:(float)width :(NSInteger)type;
3681
- - (void)setMinSizeHeight:(float)height :(NSInteger)type;
3682
- - (MasonDimensionCompat * _Nonnull)getMinSizeWidth SWIFT_WARN_UNUSED_RESULT;
3683
- - (MasonDimensionCompat * _Nonnull)getMinSizeHeight SWIFT_WARN_UNUSED_RESULT;
3684
- - (void)setSize:(float)width :(float)height;
3685
- - (void)setSizeWidth:(float)width :(NSInteger)type;
3686
- - (void)setSizeHeight:(float)height :(NSInteger)type;
3687
- - (MasonDimensionSizeCompat * _Nonnull)getSize SWIFT_WARN_UNUSED_RESULT;
3688
- - (MasonDimensionCompat * _Nonnull)getSizeWidth SWIFT_WARN_UNUSED_RESULT;
3689
- - (MasonDimensionCompat * _Nonnull)getSizeHeight SWIFT_WARN_UNUSED_RESULT;
3690
- - (void)setMaxSize:(float)width :(float)height;
3691
- - (MasonDimensionSizeCompat * _Nonnull)getMaxSize SWIFT_WARN_UNUSED_RESULT;
3692
- - (void)setMaxSizeWidth:(float)width :(NSInteger)type;
3693
- - (void)setMaxSizeHeight:(float)height :(NSInteger)type;
3694
- - (MasonDimensionCompat * _Nonnull)getMaxSizeWidth SWIFT_WARN_UNUSED_RESULT;
3695
- - (MasonDimensionCompat * _Nonnull)getMaxSizeHeight SWIFT_WARN_UNUSED_RESULT;
3696
- - (void)setGap:(float)width :(float)height;
3697
- - (void)setGapWithWidthHeightType:(float)width :(int8_t)width_type :(float)height :(int8_t)height_type;
3698
- - (MasonLengthPercentageSizeCompat * _Nonnull)getGap SWIFT_WARN_UNUSED_RESULT;
3699
- - (void)setRowGap:(float)row :(NSInteger)type;
3700
- - (void)setColumnGap:(float)column :(NSInteger)type;
3701
- - (MasonLengthPercentageCompat * _Nonnull)getRowGap SWIFT_WARN_UNUSED_RESULT;
3702
- - (MasonLengthPercentageCompat * _Nonnull)getColumnGap SWIFT_WARN_UNUSED_RESULT;
3703
- - (nonnull instancetype)initWithFrame:(CGRect)frame SWIFT_UNAVAILABLE;
3704
- @end
3705
-
3706
- SWIFT_CLASS_NAMED("MasonVerticalAlignValue")
3707
- @interface MasonVerticalAlignValue : NSObject
3708
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
3709
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
3710
- @end
3711
-
3712
- SWIFT_CLASS_NAMED("MaxSizing")
3713
- @interface MaxSizing : NSObject
3714
- @property (nonatomic, readonly) float value;
3715
- + (MaxSizing * _Nonnull)Points:(float)points SWIFT_WARN_UNUSED_RESULT;
3716
- + (MaxSizing * _Nonnull)Percent:(float)percent SWIFT_WARN_UNUSED_RESULT;
3717
- + (MaxSizing * _Nonnull)FitContent:(float)fit SWIFT_WARN_UNUSED_RESULT;
3718
- + (MaxSizing * _Nonnull)FitContentPercent:(float)fit SWIFT_WARN_UNUSED_RESULT;
3719
- + (MaxSizing * _Nonnull)Fraction:(float)flex SWIFT_WARN_UNUSED_RESULT;
3720
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MaxSizing * _Nonnull Auto;)
3721
- + (MaxSizing * _Nonnull)Auto SWIFT_WARN_UNUSED_RESULT;
3722
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MaxSizing * _Nonnull MinContent;)
3723
- + (MaxSizing * _Nonnull)MinContent SWIFT_WARN_UNUSED_RESULT;
3724
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MaxSizing * _Nonnull MaxContent;)
3725
- + (MaxSizing * _Nonnull)MaxContent SWIFT_WARN_UNUSED_RESULT;
3726
- @property (nonatomic, readonly, copy) NSString * _Nonnull cssValue;
3727
- @property (nonatomic, readonly, copy) NSString * _Nullable jsonValue;
3728
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
3729
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
3730
- @end
3731
-
3732
- SWIFT_CLASS_NAMED("MeasureOutput")
3733
- @interface MeasureOutput : NSObject
3734
- - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
3735
- @end
3736
-
3737
- @class MinSizing;
3738
- SWIFT_CLASS_NAMED("MinMax")
3739
- @interface MinMax : NSObject
3740
- - (nonnull instancetype)init:(MinSizing * _Nonnull)min :(MaxSizing * _Nonnull)max OBJC_DESIGNATED_INITIALIZER;
3741
- + (MinMax * _Nonnull)PointsWithPoints:(float)points SWIFT_WARN_UNUSED_RESULT;
3742
- + (MinMax * _Nonnull)PercentWithPercent:(float)percent SWIFT_WARN_UNUSED_RESULT;
3743
- + (MinMax * _Nonnull)FlexWithFlex:(float)flex SWIFT_WARN_UNUSED_RESULT;
3744
- + (MinMax * _Nonnull)FitContentWithFit:(float)fit SWIFT_WARN_UNUSED_RESULT;
3745
- + (MinMax * _Nonnull)FitContentPercentWithFit:(float)fit SWIFT_WARN_UNUSED_RESULT;
3746
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MinMax * _Nonnull Auto;)
3747
- + (MinMax * _Nonnull)Auto SWIFT_WARN_UNUSED_RESULT;
3748
- + (MinMax * _Nullable)fromTypeValue:(NSInteger)minType :(float)minValue :(NSInteger)maxType :(float)maxValue SWIFT_WARN_UNUSED_RESULT;
3749
- @property (nonatomic, readonly, copy) NSString * _Nonnull cssValue;
3750
- @property (nonatomic, readonly, copy) NSString * _Nullable jsonValue;
3751
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
3752
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
3753
- @end
3754
-
3755
- SWIFT_CLASS_NAMED("MinSizing")
3756
- @interface MinSizing : NSObject
3757
- @property (nonatomic, readonly) float value;
3758
- + (MinSizing * _Nonnull)Points:(float)points SWIFT_WARN_UNUSED_RESULT;
3759
- + (MinSizing * _Nonnull)Percent:(float)percent SWIFT_WARN_UNUSED_RESULT;
3760
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MinSizing * _Nonnull Auto;)
3761
- + (MinSizing * _Nonnull)Auto SWIFT_WARN_UNUSED_RESULT;
3762
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MinSizing * _Nonnull MinContent;)
3763
- + (MinSizing * _Nonnull)MinContent SWIFT_WARN_UNUSED_RESULT;
3764
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) MinSizing * _Nonnull MaxContent;)
3765
- + (MinSizing * _Nonnull)MaxContent SWIFT_WARN_UNUSED_RESULT;
3766
- @property (nonatomic, readonly, copy) NSString * _Nonnull cssValue;
3767
- @property (nonatomic, readonly, copy) NSString * _Nullable jsonValue;
3768
- - (nonnull instancetype)init SWIFT_UNAVAILABLE;
3769
- + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
3770
- @end
3771
-
3772
- @class NSUUID;
3773
- @class MasonScroll;
3774
- SWIFT_CLASS_NAMED("NSCMason")
3775
- @interface NSCMason : NSObject
3776
- @property (nonatomic, readonly) void * _Nullable nativePtr;
3777
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, strong) NSCMason * _Nonnull shared;)
3778
- + (NSCMason * _Nonnull)shared SWIFT_WARN_UNUSED_RESULT;
3779
- + (void)setShared:(NSCMason * _Nonnull)value;
3780
- - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
3781
- - (void)setDeviceScale:(float)value;
3782
- - (MasonNode * _Nonnull)nodeForView:(UIView * _Nonnull)view :(BOOL)isLeaf SWIFT_WARN_UNUSED_RESULT;
3783
- - (void)configureStyleForView:(UIView * _Nonnull)view :(SWIFT_NOESCAPE void (^ _Nonnull)(MasonStyle * _Nonnull))block;
3784
- - (MasonStyle * _Nonnull)styleForView:(UIView * _Nonnull)view SWIFT_WARN_UNUSED_RESULT;
3785
- - (MasonStyle * _Nullable)styleForViewOrNode:(id _Nullable)viewOrNode SWIFT_WARN_UNUSED_RESULT;
3786
- - (MasonLayout * _Nonnull)layoutForView:(UIView * _Nonnull)view;
3787
- - (NSUUID * _Nonnull)addEventListener:(MasonNode * _Nonnull)node :(NSString * _Nonnull)event :(void (^ _Nonnull)(MasonEvent * _Nonnull))listener;
3788
- - (BOOL)removeEventListener:(MasonNode * _Nonnull)node :(NSString * _Nonnull)event id:(NSUUID * _Nonnull)id;
3789
- - (BOOL)removeEventListener:(MasonNode * _Nonnull)node :(NSString * _Nonnull)event;
3790
- - (void)dispatch:(MasonEvent * _Nonnull)event :(MasonNode * _Nonnull)node;
3791
- @property (nonatomic, strong) MasonHTMLParser * _Nonnull htmlParser;
3792
- - (void)clear;
3793
- - (MasonDocument * _Nonnull)createDocument SWIFT_WARN_UNUSED_RESULT;
3794
- - (MasonUIView * _Nonnull)createView SWIFT_WARN_UNUSED_RESULT;
3795
- - (MasonText * _Nonnull)createTextView SWIFT_WARN_UNUSED_RESULT;
3796
- - (MasonTextNode * _Nonnull)createTextNode:(NSString * _Nonnull)data SWIFT_WARN_UNUSED_RESULT;
3797
- - (MasonText * _Nonnull)createTextViewWithType:(enum MasonTextType)type SWIFT_WARN_UNUSED_RESULT;
3798
- - (MasonImg * _Nonnull)createImageView SWIFT_WARN_UNUSED_RESULT;
3799
- - (MasonScroll * _Nonnull)createScrollView SWIFT_WARN_UNUSED_RESULT;
3800
- - (MasonButton * _Nonnull)createButton SWIFT_WARN_UNUSED_RESULT;
3801
- - (MasonNode * _Nonnull)createNode SWIFT_WARN_UNUSED_RESULT;
3802
- - (MasonBr * _Nonnull)createBr SWIFT_WARN_UNUSED_RESULT;
3803
- - (MasonInput * _Nonnull)createInput:(enum MasonInputType)type SWIFT_WARN_UNUSED_RESULT;
3804
- - (void)printTree:(MasonNode * _Nonnull)node;
3805
- - (MasonNode * _Nonnull)createTextNode SWIFT_WARN_UNUSED_RESULT;
3806
- - (MasonNode * _Nonnull)createImageNode SWIFT_WARN_UNUSED_RESULT;
3807
- - (MasonNode * _Nonnull)createButtonNode SWIFT_WARN_UNUSED_RESULT;
3808
- - (MasonNode * _Nonnull)createLineBreakNode SWIFT_WARN_UNUSED_RESULT;
3809
- - (MasonList * _Nonnull)createListViewWithIsOrdered:(BOOL)isOrdered SWIFT_WARN_UNUSED_RESULT;
3810
- - (MasonNode * _Nonnull)createListItemNode SWIFT_WARN_UNUSED_RESULT;
3811
- - (MasonLi * _Nonnull)createListItem SWIFT_WARN_UNUSED_RESULT;
3812
- - (MasonTextArea * _Nonnull)createTextArea SWIFT_WARN_UNUSED_RESULT;
3813
- @property (nonatomic) BOOL preflight;
3814
- /// The context CSS relative units resolve against, mirroring the TS side’s
3815
- /// <code>units.ts</code> and Android’s <code>Mason.shared</code>. <code>rem</code> needs a root font size (the
3816
- /// CSS default is 16); the viewport is read from the key window, and is 0 until
3817
- /// one exists — an unresolvable viewport unit collapses to 0 rather than
3818
- /// silently becoming a bare number in the wrong unit.
3819
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class) float rootFontSize;)
3820
- + (float)rootFontSize SWIFT_WARN_UNUSED_RESULT;
3821
- + (void)setRootFontSize:(float)value;
3822
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly) CGSize viewportSize;)
3823
- + (CGSize)viewportSize SWIFT_WARN_UNUSED_RESULT;
3824
- /// The display scale every layout value is converted through.
3825
- /// Cached: resolving it walks <code>connectedScenes</code> and each scene’s windows,
3826
- /// and it’s read on the hottest paths there are (once per text measure,
3827
- /// once per node applying a computed layout). Invalidated by the
3828
- /// notifications below when the window moves between displays.
3829
- SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly) float scale;)
3830
- + (float)scale SWIFT_WARN_UNUSED_RESULT;
3831
- /// Drop the cached scale; the next read resolves it again.
3832
- + (void)invalidateScale;
3833
- @end
3834
-
3835
- @interface NSObject (SWIFT_EXTENSION(Mason))
3836
- @property (nonatomic, copy) NSString * _Nonnull mason_innerHTML;
3837
- - (NSUUID * _Nonnull)mason_addEventListener:(NSString * _Nonnull)event :(void (^ _Nonnull)(MasonEvent * _Nonnull))listener;
3838
- - (BOOL)mason_removeEventListener:(NSString * _Nonnull)event id:(NSUUID * _Nonnull)id;
3839
- - (BOOL)mason_removeEventListener:(NSString * _Nonnull)event;
3840
- - (void)mason_dispatch:(MasonEvent * _Nonnull)event;
3841
- - (void)mason_syncStyle:(NSString * _Nonnull)low :(NSString * _Nonnull)high;
3842
- - (void)mason_addView:(UIView * _Nonnull)view;
3843
- - (void)mason_addView:(UIView * _Nonnull)view at:(NSInteger)at;
3844
- - (void)mason_markNodeDirty;
3845
- - (BOOL)mason_isNodeDirty SWIFT_WARN_UNUSED_RESULT;
3846
- - (void)mason_configure:(SWIFT_NOESCAPE void (^ _Nonnull)(MasonStyle * _Nonnull))block;
3847
- - (MasonLayout * _Nonnull)mason_layout;
3848
- - (void)mason_compute;
3849
- - (void)mason_computeWithWidth:(float)width height:(float)height;
3850
- - (void)mason_computeMaxContent;
3851
- - (void)mason_computeMinContent;
3852
- - (void)mason_computeWithSize:(float)width :(float)height;
3853
- - (void)mason_computeWithViewSize;
3854
- - (void)mason_computeWithViewSizeWithLayout:(BOOL)layout;
3855
- - (void)mason_computeWithMaxContent;
3856
- - (void)mason_markRootComputeApplied;
3857
- /// <code>mason_markRootComputeApplied</code> plus the box the host measured against, so
3858
- /// a later <code>autoComputeIfRoot</code> reuses it rather than the superview’s bounds.
3859
- - (void)mason_markRootComputeAppliedWithSize:(float)width :(float)height;
3860
- - (void)mason_computeWithMinContent;
3861
- - (void)mason_attachAndApply;
3862
- - (void)mason_requestLayout;
3863
- - (void)mason_invalidateLayout;
3864
- - (void)mason_append:(id <MasonElementObjc> _Nonnull)element;
3865
- - (void)mason_appendWithText:(NSString * _Nonnull)text;
3866
- - (void)mason_appendWithNode:(MasonNode * _Nonnull)node;
3867
- - (void)mason_appendWithTexts:(NSArray<NSString *> * _Nonnull)texts;
3868
- - (void)mason_appendWithElements:(NSArray<id <MasonElementObjc>> * _Nonnull)elements;
3869
- - (void)mason_appendWithNodes:(NSArray<MasonNode *> * _Nonnull)nodes;
3870
- - (void)mason_prepend:(id <MasonElementObjc> _Nonnull)element;
3871
- - (void)mason_prependWithText:(NSString * _Nonnull)text;
3872
- - (void)mason_prependWithNode:(MasonNode * _Nonnull)node;
3873
- - (void)mason_prependWithTexts:(NSArray<NSString *> * _Nonnull)texts;
3874
- - (void)mason_prependWithElements:(NSArray<id <MasonElementObjc>> * _Nonnull)elements;
3875
- - (void)mason_prependWithNodes:(NSArray<MasonNode *> * _Nonnull)nodes;
3876
- - (void)mason_addChildAtText:(NSString * _Nonnull)text :(NSInteger)index;
3877
- - (void)mason_addChildAtElement:(id <MasonElementObjc> _Nonnull)element :(NSInteger)index;
3878
- - (void)mason_addChildAtNode:(MasonNode * _Nonnull)node :(NSInteger)index;
3879
- - (void)mason_replaceChildAtText:(NSString * _Nonnull)text :(NSInteger)index;
3880
- - (void)mason_replaceChildAtElement:(id <MasonElementObjc> _Nonnull)element :(NSInteger)index;
3881
- - (void)mason_replaceChildAtNode:(MasonNode * _Nonnull)node :(NSInteger)index;
3882
- /// Remove the child node (view or text node) at <code>index</code> from the mason tree.
3883
- /// Counterpart to <code>mason_addChildAt</code>; <code>MasonNode.removeChildAt</code> already
3884
- /// handles both <code>MasonTextNode</code> and element children.
3885
- - (void)mason_removeChildAt:(NSInteger)index;
3886
- /// Remove a specific child node (e.g. the <code>MasonTextNode</code> a framework stamped
3887
- /// onto its JS text node) without needing its index.
3888
- - (void)mason_removeChildNode:(MasonNode * _Nonnull)node;
3889
- @end
3890
-
3891
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonObjectFit, "ObjectFit", open) {
3892
- MasonObjectFitContain = 0,
3893
- MasonObjectFitCover = 1,
3894
- MasonObjectFitFill = 2,
3895
- MasonObjectFitNone = 3,
3896
- MasonObjectFitScaleDown = 4,
3897
- };
3898
-
3899
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonOverflow, "Overflow", open) {
3900
- MasonOverflowVisible = 0,
3901
- MasonOverflowHidden = 1,
3902
- MasonOverflowScroll = 2,
3903
- MasonOverflowClip = 3,
3904
- MasonOverflowAuto = 4,
3905
- };
3906
-
3907
- typedef SWIFT_ENUM_NAMED(NSInteger, MasonPosition, "Position", open) {
3908
- MasonPositionRelative = 0,
3909
- MasonPositionAbsolute = 1,
1871
+ MasonPositionStatic = 0,
1872
+ MasonPositionRelative = 1,
1873
+ MasonPositionAbsolute = 2,
1874
+ MasonPositionFixed = 3,
1875
+ MasonPositionSticky = 4,
3910
1876
  };
3911
1877
 
3912
1878
  typedef SWIFT_ENUM_NAMED(uint16_t, PseudoState, "PseudoState", open) {