@rnmapbox/maps 10.1.9 → 10.1.10

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.
@@ -25,7 +25,7 @@ using namespace facebook::react;
25
25
  if (self = [super initWithFrame:frame]) {
26
26
  static const auto defaultProps = std::make_shared<const RNMBXMarkerViewProps>();
27
27
  _props = defaultProps;
28
- [self prepareView];
28
+ [self prepareView];
29
29
  }
30
30
 
31
31
  return self;
@@ -39,26 +39,18 @@ using namespace facebook::react;
39
39
 
40
40
  - (void)prepareForRecycle
41
41
  {
42
- [super prepareForRecycle];
43
- [self prepareView];
42
+ [super prepareForRecycle];
43
+ [self prepareView];
44
44
  }
45
45
 
46
46
  - (void)mountChildComponentView:(UIView<RCTComponentViewProtocol> *)childComponentView index:(NSInteger)index
47
47
  {
48
- if ([childComponentView isKindOfClass:[RCTViewComponentView class]] && ((RCTViewComponentView *)childComponentView).contentView != nil) {
49
- [_view insertSubview:((RCTViewComponentView *)childComponentView).contentView atIndex:index];
50
- } else {
51
- [_view insertSubview:childComponentView atIndex:index];
52
- }
48
+ [_view insertSubview:childComponentView atIndex:index];
53
49
  }
54
50
 
55
51
  - (void)unmountChildComponentView:(UIView<RCTComponentViewProtocol> *)childComponentView index:(NSInteger)index
56
52
  {
57
- if ([childComponentView isKindOfClass:[RCTViewComponentView class]] && ((RCTViewComponentView *)childComponentView).contentView != nil) {
58
- [((RCTViewComponentView *)childComponentView).contentView removeFromSuperview];
59
- } else {
60
- [childComponentView removeFromSuperview];
61
- }
53
+ [childComponentView removeFromSuperview];
62
54
  }
63
55
 
64
56
  #pragma mark - RCTComponentViewProtocol
@@ -17,27 +17,20 @@ using namespace facebook::react;
17
17
  @end
18
18
 
19
19
  @implementation RNMBXMarkerViewContentComponentView {
20
- RNMBXMarkerView *_view;
20
+ UIView *_view;
21
21
  CGRect _frame;
22
22
  }
23
23
 
24
24
  - (instancetype)initWithFrame:(CGRect)frame
25
25
  {
26
26
  if (self = [super initWithFrame:frame]) {
27
- static const auto defaultProps = std::make_shared<const RNMBXMarkerViewProps>();
27
+ static const auto defaultProps = std::make_shared<const RNMBXMarkerViewContentProps>();
28
28
  _props = defaultProps;
29
29
  _frame = frame;
30
- [self prepareView];
31
30
  }
32
31
  return self;
33
32
  }
34
33
 
35
- - (void)prepareView
36
- {
37
- _view = [[RNMBXMarkerView alloc] initWithFrame:_frame];
38
- self.contentView = _view;
39
- }
40
-
41
34
  #pragma mark - RCTComponentViewProtocol
42
35
 
43
36
  + (ComponentDescriptorProvider)componentDescriptorProvider
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@rnmapbox/maps",
3
3
  "description": "A Mapbox react native module for creating custom maps",
4
- "version": "10.1.9",
4
+ "version": "10.1.10",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },