fix(modules): add stylus loader as an option to be uncommented (#3710)
This commit is contained in:
1 parent
dc929d3df5
commit
7c57f67844
9 files changed
+92
-9
No files matched your search
@@ -189,7 +189,7 @@ class SegmentationService extends PubSubService {
|
||||
);
|
||||
}
|
||||
|
||||
if (active !== undefined) {
|
||||
if (active === true) {
|
||||
this._setActiveSegment(segmentationId, segmentIndex, suppressEvents);
|
||||
}
|
||||
|
||||
@@ -399,6 +399,23 @@ class SegmentationService extends PubSubService {
|
||||
return segmentations && segmentations.map(m => this.segmentations[Object.keys(m)[0]]);
|
||||
}
|
||||
|
||||
public getActiveSegmentation(): Segmentation {
|
||||
const segmentations = this.getSegmentations();
|
||||
|
||||
return segmentations.find(segmentation => segmentation.isActive);
|
||||
}
|
||||
|
||||
public getActiveSegment() {
|
||||
const activeSegmentation = this.getActiveSegmentation();
|
||||
const { activeSegmentIndex, segments } = activeSegmentation;
|
||||
|
||||
if (activeSegmentIndex === null) {
|
||||
return;
|
||||
}
|
||||
|
||||
return segments[activeSegmentIndex];
|
||||
}
|
||||
|
||||
/**
|
||||
* Get specific segmentation by its id.
|
||||
*
|
||||
|
||||
Reference in new issue
Block a user