betterplace_explorer 0.0.1.pre.alpha5 → 0.0.1.pre.alpha6

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: bcb807d8798a3a87970a7d3b7288d32556c762bd
4
- data.tar.gz: d9dd1c78d6d74e7ec61f06db0fb2e532463821bb
3
+ metadata.gz: b7d0dcbcf2a2c6b11cec16b6987e36113ee7d9ef
4
+ data.tar.gz: 13a70d7bff52d11915b0f6ecc91387fb1b71137e
5
5
  SHA512:
6
- metadata.gz: 68c0e930eeb863f281b94848a532e310d6f2d47c2dac9eee7a3fa431ec8850485bbb8823030c8ced6d272f292b3d52fccb03c447a2e2a47c73e1aee2ebc6bb3c
7
- data.tar.gz: f76264613878e244c40b2bb3ca5b8cc1047c1daccb6f559658e07f0944d9e0159600633c44e736cf14326bf447e73609ad7854ed14dff4eb19ee55eceabed689
6
+ metadata.gz: b6b98f88a8abc4ebe509e78801eb198591511007d726b67287de06317ce5909aa50c65abe6cd1c3dd61d006fb9a97b887f8d7eefd8924cc7374e48a4d18201a8
7
+ data.tar.gz: 8d9e51b44e228b0ae81e7fee28d86303c4ebd1048a04e734b29dcfbcbee4edb7cb6fdb29873bff21b551dbe0b3b5594d14c65836546e723c4454369c3339c26c
@@ -110,9 +110,24 @@
110
110
  return _react2['default'].createElement(
111
111
  'div',
112
112
  { className: 'betterplace-explorer' },
113
- _react2['default'].createElement(_LocationInput2['default'], { changeLocation: this.changeLocation }),
114
- _react2['default'].createElement(_VolunteeringList2['default'], { records: this.state.records, totalEntries: this.state.totalEntries, setHighlightRecord: this.setHighlightRecord, currentPage: this.state.currentPage, totalPages: this.state.totalPages, changePage: this.changePage }),
115
- _react2['default'].createElement(_Map2['default'], { records: this.state.records, mapIdle: this.loadByBoundingBox, changeBounds: this.state.changeBounds, highlightRecord: this.state.highlightRecord, setHighlightRecord: this.setHighlightRecord })
113
+ _react2['default'].createElement(_LocationInput2['default'], {
114
+ changeLocation: this.changeLocation
115
+ }),
116
+ _react2['default'].createElement(_VolunteeringList2['default'], {
117
+ changePage: this.changePage,
118
+ currentPage: this.state.currentPage,
119
+ records: this.state.records,
120
+ setHighlightRecord: this.setHighlightRecord,
121
+ totalEntries: this.state.totalEntries,
122
+ totalPages: this.state.totalPages
123
+ }),
124
+ _react2['default'].createElement(_Map2['default'], {
125
+ changeBounds: this.state.changeBounds,
126
+ highlightRecord: this.state.highlightRecord,
127
+ mapIdle: this.loadByBoundingBox,
128
+ records: this.state.records,
129
+ setHighlightRecord: this.setHighlightRecord
130
+ })
116
131
  );
117
132
  }
118
133
 
@@ -26037,6 +26052,10 @@
26037
26052
 
26038
26053
  var _react2 = _interopRequireDefault(_react);
26039
26054
 
26055
+ var _reactDom = __webpack_require__(99);
26056
+
26057
+ var _reactDom2 = _interopRequireDefault(_reactDom);
26058
+
26040
26059
  var _Pagination = __webpack_require__(230);
26041
26060
 
26042
26061
  var _Pagination2 = _interopRequireDefault(_Pagination);
@@ -26055,7 +26074,11 @@
26055
26074
  var _this = this;
26056
26075
 
26057
26076
  var volunteeringNodes = this.props.records.map(function (record) {
26058
- return _react2['default'].createElement(_Volunteering2['default'], { record: record, key: record.id, setHighlightRecord: _this.props.setHighlightRecord });
26077
+ return _react2['default'].createElement(_Volunteering2['default'], {
26078
+ key: record.id,
26079
+ record: record,
26080
+ setHighlightRecord: _this.props.setHighlightRecord
26081
+ });
26059
26082
  });
26060
26083
 
26061
26084
  return _react2['default'].createElement(
@@ -26077,12 +26100,36 @@
26077
26100
  _react2['default'].createElement(
26078
26101
  'div',
26079
26102
  null,
26080
- _react2['default'].createElement(_Pagination2['default'], { currentPage: this.props.currentPage, totalPages: this.props.totalPages, changePage: this.props.changePage })
26103
+ _react2['default'].createElement(_Pagination2['default'], {
26104
+ changePage: this.changePage,
26105
+ currentPage: this.props.currentPage,
26106
+ totalPages: this.props.totalPages
26107
+ })
26081
26108
  )
26082
26109
  );
26083
26110
  }
26084
26111
 
26085
26112
  return render;
26113
+ }(),
26114
+
26115
+ changePage: function () {
26116
+ function changePage(toPage) {
26117
+ this.shouldScrollTop = true;
26118
+ this.props.changePage(toPage);
26119
+ }
26120
+
26121
+ return changePage;
26122
+ }(),
26123
+
26124
+ componentDidUpdate: function () {
26125
+ function componentDidUpdate() {
26126
+ if (this.shouldScrollTop) {
26127
+ this.shouldScrollTop = false;
26128
+ _reactDom2['default'].findDOMNode(this).scrollTop = 0;
26129
+ }
26130
+ }
26131
+
26132
+ return componentDidUpdate;
26086
26133
  }()
26087
26134
  });
26088
26135
 
@@ -26092,7 +26139,7 @@
26092
26139
  /* 230 */
26093
26140
  /***/ function(module, exports, __webpack_require__) {
26094
26141
 
26095
- "use strict";
26142
+ 'use strict';
26096
26143
 
26097
26144
  Object.defineProperty(exports, "__esModule", {
26098
26145
  value: true
@@ -26102,84 +26149,41 @@
26102
26149
 
26103
26150
  var _react2 = _interopRequireDefault(_react);
26104
26151
 
26105
- function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
26152
+ var _PaginationNextButton = __webpack_require__(280);
26106
26153
 
26107
- var PrevButton = _react2["default"].createClass({
26108
- displayName: "PrevButton",
26154
+ var _PaginationNextButton2 = _interopRequireDefault(_PaginationNextButton);
26109
26155
 
26110
- render: function () {
26111
- function render() {
26112
- if (this.props.currentPage > 1) {
26113
- return _react2["default"].createElement(
26114
- "li",
26115
- { className: "previous" },
26116
- _react2["default"].createElement(
26117
- "a",
26118
- { href: "#", onClick: this.props.handleClick },
26119
- _react2["default"].createElement(
26120
- "span",
26121
- { "aria-hidden": "true" },
26122
- "←"
26123
- ),
26124
- " zurück"
26125
- )
26126
- );
26127
- } else {
26128
- return null;
26129
- }
26130
- }
26156
+ var _PaginationPrevButton = __webpack_require__(281);
26131
26157
 
26132
- return render;
26133
- }()
26134
- });
26135
-
26136
- var NextButton = _react2["default"].createClass({
26137
- displayName: "NextButton",
26158
+ var _PaginationPrevButton2 = _interopRequireDefault(_PaginationPrevButton);
26138
26159
 
26139
- render: function () {
26140
- function render() {
26141
- if (this.props.currentPage < this.props.totalPages) {
26142
- return _react2["default"].createElement(
26143
- "li",
26144
- { className: "next" },
26145
- _react2["default"].createElement(
26146
- "a",
26147
- { href: "#", onClick: this.props.handleClick },
26148
- "weiter ",
26149
- _react2["default"].createElement(
26150
- "span",
26151
- { "aria-hidden": "true" },
26152
- "→"
26153
- )
26154
- )
26155
- );
26156
- } else {
26157
- return null;
26158
- }
26159
- }
26160
-
26161
- return render;
26162
- }()
26163
- });
26160
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
26164
26161
 
26165
- var Pagination = _react2["default"].createClass({
26166
- displayName: "Pagination",
26162
+ var Pagination = _react2['default'].createClass({
26163
+ displayName: 'Pagination',
26167
26164
 
26168
26165
  render: function () {
26169
26166
  function render() {
26170
26167
  if (this.props.currentPage) {
26171
- return _react2["default"].createElement(
26172
- "nav",
26173
- { className: "bpe--pagination" },
26174
- _react2["default"].createElement(
26175
- "ul",
26176
- { className: "pager" },
26177
- _react2["default"].createElement(PrevButton, { currentPage: this.props.currentPage, handleClick: this.previousPage }),
26178
- "Seite ",
26168
+ return _react2['default'].createElement(
26169
+ 'nav',
26170
+ { className: 'bpe--pagination' },
26171
+ _react2['default'].createElement(
26172
+ 'ul',
26173
+ { className: 'pager' },
26174
+ _react2['default'].createElement(_PaginationPrevButton2['default'], {
26175
+ currentPage: this.props.currentPage,
26176
+ handleClick: this.previousPage
26177
+ }),
26178
+ 'Seite ',
26179
26179
  this.props.currentPage,
26180
- " von ",
26180
+ ' von ',
26181
26181
  this.props.totalPages,
26182
- _react2["default"].createElement(NextButton, { currentPage: this.props.currentPage, totalPages: this.props.totalPages, handleClick: this.nextPage })
26182
+ _react2['default'].createElement(_PaginationNextButton2['default'], {
26183
+ currentPage: this.props.currentPage,
26184
+ handleClick: this.nextPage,
26185
+ totalPages: this.props.totalPages
26186
+ })
26183
26187
  )
26184
26188
  );
26185
26189
  } else {
@@ -26192,7 +26196,7 @@
26192
26196
 
26193
26197
  previousPage: function () {
26194
26198
  function previousPage(event) {
26195
- this.props.changePage(this.props.currentPage - 1);
26199
+ this.changePage(this.props.currentPage - 1);
26196
26200
  }
26197
26201
 
26198
26202
  return previousPage;
@@ -26200,14 +26204,22 @@
26200
26204
 
26201
26205
  nextPage: function () {
26202
26206
  function nextPage(event) {
26203
- this.props.changePage(this.props.currentPage + 1);
26207
+ this.changePage(this.props.currentPage + 1);
26204
26208
  }
26205
26209
 
26206
26210
  return nextPage;
26211
+ }(),
26212
+
26213
+ changePage: function () {
26214
+ function changePage(toPage) {
26215
+ this.props.changePage(toPage);
26216
+ }
26217
+
26218
+ return changePage;
26207
26219
  }()
26208
26220
  });
26209
26221
 
26210
- exports["default"] = Pagination;
26222
+ exports['default'] = Pagination;
26211
26223
 
26212
26224
  /***/ },
26213
26225
  /* 231 */
@@ -26357,14 +26369,14 @@
26357
26369
 
26358
26370
  var markers = this.props.records.map(function (record) {
26359
26371
  return _react2['default'].createElement(_reactGoogleMaps.Marker, {
26360
- position: { lat: record.latitude, lng: record.longitude },
26361
- key: record.id,
26372
+ customInfo: 'Marker A',
26362
26373
  icon: record == _this.props.highlightRecord ? highlightPin : defaultPin,
26363
- zIndex: record == _this.props.highlightRecord ? 10000 : null,
26374
+ key: record.id,
26364
26375
  onClick: _this.handleMarkerClick.bind(_this, record),
26365
- onMouseover: _this.handleMarkerMouseOver.bind(_this, record),
26366
26376
  onMouseout: _this.handleMarkerMouseOut.bind(_this, record),
26367
- customInfo: 'Marker A'
26377
+ onMouseover: _this.handleMarkerMouseOver.bind(_this, record),
26378
+ position: { lat: record.latitude, lng: record.longitude },
26379
+ zIndex: record == _this.props.highlightRecord ? 10000 : null
26368
26380
  });
26369
26381
  });
26370
26382
 
@@ -26376,17 +26388,17 @@
26376
26388
  googleMapElement: _react2['default'].createElement(
26377
26389
  _reactGoogleMaps.GoogleMap,
26378
26390
  {
26391
+ defaultCenter: { lat: 52.49928, lng: 13.44944 },
26392
+ defaultZoom: 5,
26393
+ onClick: this.handleMapClick,
26394
+ onIdle: this.idle,
26379
26395
  ref: function () {
26380
26396
  function ref(map) {
26381
26397
  return _this.googlemap = map;
26382
26398
  }
26383
26399
 
26384
26400
  return ref;
26385
- }(),
26386
- defaultZoom: 5,
26387
- defaultCenter: { lat: 52.49928, lng: 13.44944 },
26388
- onIdle: this.idle,
26389
- onClick: this.handleMapClick
26401
+ }()
26390
26402
  },
26391
26403
  markers
26392
26404
  )
@@ -26398,7 +26410,7 @@
26398
26410
  }(),
26399
26411
 
26400
26412
  componentDidUpdate: function () {
26401
- function componentDidUpdate(next, prev) {
26413
+ function componentDidUpdate(prevProps, prevState) {
26402
26414
  if (this.props.changeBounds) {
26403
26415
  this.googlemap.fitBounds(this.props.changeBounds);
26404
26416
  this.googlemap.props.map.setZoom(this.googlemap.getZoom() + 1);
@@ -32608,5 +32620,99 @@
32608
32620
 
32609
32621
  exports['default'] = LocationInput;
32610
32622
 
32623
+ /***/ },
32624
+ /* 280 */
32625
+ /***/ function(module, exports, __webpack_require__) {
32626
+
32627
+ "use strict";
32628
+
32629
+ Object.defineProperty(exports, "__esModule", {
32630
+ value: true
32631
+ });
32632
+
32633
+ var _react = __webpack_require__(1);
32634
+
32635
+ var _react2 = _interopRequireDefault(_react);
32636
+
32637
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
32638
+
32639
+ var PaginationNextButton = _react2["default"].createClass({
32640
+ displayName: "PaginationNextButton",
32641
+
32642
+ render: function () {
32643
+ function render() {
32644
+ if (this.props.currentPage < this.props.totalPages) {
32645
+ return _react2["default"].createElement(
32646
+ "li",
32647
+ { className: "next" },
32648
+ _react2["default"].createElement(
32649
+ "a",
32650
+ { href: "#", onClick: this.props.handleClick },
32651
+ "weiter ",
32652
+ _react2["default"].createElement(
32653
+ "span",
32654
+ { "aria-hidden": "true" },
32655
+ "→"
32656
+ )
32657
+ )
32658
+ );
32659
+ } else {
32660
+ return null;
32661
+ }
32662
+ }
32663
+
32664
+ return render;
32665
+ }()
32666
+ });
32667
+
32668
+ exports["default"] = PaginationNextButton;
32669
+
32670
+ /***/ },
32671
+ /* 281 */
32672
+ /***/ function(module, exports, __webpack_require__) {
32673
+
32674
+ "use strict";
32675
+
32676
+ Object.defineProperty(exports, "__esModule", {
32677
+ value: true
32678
+ });
32679
+
32680
+ var _react = __webpack_require__(1);
32681
+
32682
+ var _react2 = _interopRequireDefault(_react);
32683
+
32684
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
32685
+
32686
+ var PaginationPrevButton = _react2["default"].createClass({
32687
+ displayName: "PaginationPrevButton",
32688
+
32689
+ render: function () {
32690
+ function render() {
32691
+ if (this.props.currentPage > 1) {
32692
+ return _react2["default"].createElement(
32693
+ "li",
32694
+ { className: "previous" },
32695
+ _react2["default"].createElement(
32696
+ "a",
32697
+ { href: "#", onClick: this.props.handleClick },
32698
+ _react2["default"].createElement(
32699
+ "span",
32700
+ { "aria-hidden": "true" },
32701
+ "←"
32702
+ ),
32703
+ " zurück"
32704
+ )
32705
+ );
32706
+ } else {
32707
+ return null;
32708
+ }
32709
+ }
32710
+
32711
+ return render;
32712
+ }()
32713
+ });
32714
+
32715
+ exports["default"] = PaginationPrevButton;
32716
+
32611
32717
  /***/ }
32612
32718
  /******/ ]);
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: betterplace_explorer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1.pre.alpha5
4
+ version: 0.0.1.pre.alpha6
5
5
  platform: ruby
6
6
  authors:
7
7
  - betterplace developers
@@ -46,7 +46,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
46
46
  version: 1.3.1
47
47
  requirements: []
48
48
  rubyforge_project:
49
- rubygems_version: 2.6.4
49
+ rubygems_version: 2.5.1
50
50
  signing_key:
51
51
  specification_version: 4
52
52
  summary: An awesome explorer