Skip to content

Commit ea593a9

Browse files
authored
Merge pull request #3125 from IgniteUI/snovoselski/update-slider-samples-vnext
fix(slider): add import of hammer module for interactions to work properly - vNext
2 parents 28d2b3a + 26e8d0c commit ea593a9

1 file changed

Lines changed: 27 additions & 27 deletions

File tree

live-editing/configs/SliderConfigGenerator.ts

Lines changed: 27 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,20 @@ import {IgxButtonModule,
22
IgxIconModule,
33
IgxInputGroupModule,
44
IgxSliderModule} from 'igniteui-angular';
5+
import { HammerModule } from '@angular/platform-browser';
56
import {AppModuleConfig, Config, IConfigGenerator} from 'igniteui-live-editing'
67
export class SliderConfigGenerator implements IConfigGenerator {
78

8-
99
public generateConfigs(): Config[] {
1010
const configs = new Array<Config>();
1111

1212
// slider sample 1
1313
configs.push(new Config({
1414
component: 'SliderSample1Component',
1515
appModuleConfig: new AppModuleConfig({
16-
imports: ['IgxInputGroupModule', 'IgxSliderModule', 'SliderSample1Component'],
16+
imports: ['IgxInputGroupModule', 'IgxSliderModule', 'SliderSample1Component', 'HammerModule'],
1717
ngDeclarations: ['SliderSample1Component'],
18-
ngImports: ['IgxInputGroupModule', 'IgxSliderModule']
18+
ngImports: ['IgxInputGroupModule', 'IgxSliderModule', 'HammerModule']
1919
}),
2020
shortenComponentPathBy: "/interactions/slider/"
2121
}));
@@ -24,9 +24,9 @@ export class SliderConfigGenerator implements IConfigGenerator {
2424
configs.push(new Config({
2525
component: 'SliderSample2Component',
2626
appModuleConfig: new AppModuleConfig({
27-
imports: ['IgxSliderModule', 'SliderSample2Component'],
27+
imports: ['IgxSliderModule', 'SliderSample2Component', 'HammerModule'],
2828
ngDeclarations: ['SliderSample2Component'],
29-
ngImports: ['IgxSliderModule']
29+
ngImports: ['IgxSliderModule', 'HammerModule']
3030
}),
3131
shortenComponentPathBy: "/interactions/slider/"
3232
}));
@@ -35,9 +35,9 @@ export class SliderConfigGenerator implements IConfigGenerator {
3535
configs.push(new Config({
3636
component: 'SliderSample3Component',
3737
appModuleConfig: new AppModuleConfig({
38-
imports: ['IgxInputGroupModule', 'IgxSliderModule', 'SliderSample3Component'],
38+
imports: ['IgxInputGroupModule', 'IgxSliderModule', 'SliderSample3Component', 'HammerModule'],
3939
ngDeclarations: ['SliderSample3Component'],
40-
ngImports: ['IgxInputGroupModule', 'IgxSliderModule']
40+
ngImports: ['IgxInputGroupModule', 'IgxSliderModule', 'HammerModule']
4141
}),
4242
shortenComponentPathBy: "/interactions/slider/"
4343
}));
@@ -46,9 +46,9 @@ export class SliderConfigGenerator implements IConfigGenerator {
4646
configs.push(new Config({
4747
component: 'SliderSample4Component',
4848
appModuleConfig: new AppModuleConfig({
49-
imports: ['IgxSliderModule', 'SliderSample4Component'],
49+
imports: ['IgxSliderModule', 'SliderSample4Component', 'HammerModule'],
5050
ngDeclarations: ['SliderSample4Component'],
51-
ngImports: ['IgxSliderModule']
51+
ngImports: ['IgxSliderModule', 'HammerModule']
5252
}),
5353
shortenComponentPathBy: "/interactions/slider/"
5454
}));
@@ -57,9 +57,9 @@ export class SliderConfigGenerator implements IConfigGenerator {
5757
configs.push(new Config({
5858
component: 'SliderSample5Component',
5959
appModuleConfig: new AppModuleConfig({
60-
imports: ['IgxSliderModule', 'SliderSample5Component'],
60+
imports: ['IgxSliderModule', 'SliderSample5Component', 'HammerModule'],
6161
ngDeclarations: ['SliderSample5Component'],
62-
ngImports: ['IgxSliderModule']
62+
ngImports: ['IgxSliderModule', 'HammerModule']
6363
}),
6464
shortenComponentPathBy: "/interactions/slider/"
6565
}));
@@ -68,79 +68,79 @@ export class SliderConfigGenerator implements IConfigGenerator {
6868
configs.push(new Config({
6969
component: 'SliderSample6Component',
7070
appModuleConfig: new AppModuleConfig({
71-
imports: ['IgxSliderModule', 'SliderSample6Component'],
71+
imports: ['IgxSliderModule', 'SliderSample6Component', 'HammerModule'],
7272
ngDeclarations: ['SliderSample6Component'],
73-
ngImports: ['IgxSliderModule']
73+
ngImports: ['IgxSliderModule', 'HammerModule']
7474
}),
7575
shortenComponentPathBy: "/interactions/slider/"
7676
}));
7777

7878
configs.push(new Config({
7979
component: 'SliderSecondaryTicksMirrorComponent',
8080
appModuleConfig: new AppModuleConfig({
81-
imports: ['IgxButtonModule', 'IgxIconModule', 'IgxSliderModule', 'SliderSecondaryTicksMirrorComponent'],
81+
imports: ['IgxButtonModule', 'IgxIconModule', 'IgxSliderModule', 'SliderSecondaryTicksMirrorComponent', 'HammerModule'],
8282
ngDeclarations: ['SliderSecondaryTicksMirrorComponent'],
83-
ngImports: ['IgxButtonModule', 'IgxIconModule', 'IgxSliderModule']
83+
ngImports: ['IgxButtonModule', 'IgxIconModule', 'IgxSliderModule', 'HammerModule']
8484
}),
8585
shortenComponentPathBy: "/interactions/slider/"
8686
}));
8787

8888
configs.push(new Config({
8989
component: 'SliderDiscreteTicksBottomComponent',
9090
appModuleConfig: new AppModuleConfig({
91-
imports: ['IgxSliderModule', 'SliderDiscreteTicksBottomComponent'],
91+
imports: ['IgxSliderModule', 'SliderDiscreteTicksBottomComponent', 'HammerModule'],
9292
ngDeclarations: ['SliderDiscreteTicksBottomComponent'],
93-
ngImports: ['IgxSliderModule']
93+
ngImports: ['IgxSliderModule', 'HammerModule']
9494
}),
9595
shortenComponentPathBy: "/interactions/slider/"
9696
}));
9797

9898
configs.push(new Config({
9999
component: 'SliderTicksBottomtotopLabelsComponent',
100100
appModuleConfig: new AppModuleConfig({
101-
imports: ['IgxInputGroupModule', 'IgxSliderModule', 'SliderTicksBottomtotopLabelsComponent'],
101+
imports: ['IgxInputGroupModule', 'IgxSliderModule', 'SliderTicksBottomtotopLabelsComponent', 'HammerModule'],
102102
ngDeclarations: ['SliderTicksBottomtotopLabelsComponent'],
103-
ngImports: ['IgxInputGroupModule', 'IgxSliderModule']
103+
ngImports: ['IgxInputGroupModule', 'IgxSliderModule', 'HammerModule']
104104
}),
105105
shortenComponentPathBy: "/interactions/slider/"
106106
}));
107107

108108
configs.push(new Config({
109109
component: 'SliderPrimaryTicksTopComponent',
110110
appModuleConfig: new AppModuleConfig({
111-
imports: ['IgxSliderModule', 'SliderPrimaryTicksTopComponent'],
111+
imports: ['IgxSliderModule', 'SliderPrimaryTicksTopComponent', 'HammerModule'],
112112
ngDeclarations: ['SliderPrimaryTicksTopComponent'],
113-
ngImports: ['IgxSliderModule']
113+
ngImports: ['IgxSliderModule', 'HammerModule']
114114
}),
115115
shortenComponentPathBy: "/interactions/slider/"
116116
}));
117117

118118
configs.push(new Config({
119119
component: 'SliderTimeframeComponent',
120120
appModuleConfig: new AppModuleConfig({
121-
imports: ['IgxSliderModule', 'SliderTimeframeComponent'],
121+
imports: ['IgxSliderModule', 'SliderTimeframeComponent', 'HammerModule'],
122122
ngDeclarations: ['SliderTimeframeComponent'],
123-
ngImports: ['IgxSliderModule']
123+
ngImports: ['IgxSliderModule', 'HammerModule']
124124
}),
125125
shortenComponentPathBy: "/interactions/slider/"
126126
}));
127127

128128
configs.push(new Config({
129129
component: 'TickLabelsTemplateComponent',
130130
appModuleConfig: new AppModuleConfig({
131-
imports: ['IgxSliderModule', 'TickLabelsTemplateComponent'],
131+
imports: ['IgxSliderModule', 'TickLabelsTemplateComponent', 'HammerModule'],
132132
ngDeclarations: ['TickLabelsTemplateComponent'],
133-
ngImports: ['IgxSliderModule']
133+
ngImports: ['IgxSliderModule', 'HammerModule']
134134
}),
135135
shortenComponentPathBy: "/interactions/slider/"
136136
}));
137137

138138
configs.push(new Config({
139139
component: 'AppSliderStylingComponent',
140140
appModuleConfig: new AppModuleConfig({
141-
imports: ['IgxSliderModule', 'AppSliderStylingComponent'],
141+
imports: ['IgxSliderModule', 'AppSliderStylingComponent', 'HammerModule'],
142142
ngDeclarations: ['AppSliderStylingComponent'],
143-
ngImports: ['IgxSliderModule']
143+
ngImports: ['IgxSliderModule', 'HammerModule']
144144
}),
145145
shortenComponentPathBy: "/interactions/slider/"
146146
}));

0 commit comments

Comments
 (0)