@@ -11,34 +11,25 @@ public partial class ButtonController : Controller
1111 {
1212 public IActionResult ProgressButton ( )
1313 {
14- List < object > spinSettings = new List < object > ( ) ;
15- spinSettings . Add ( new {
16- position = "Right"
17- } ) ;
18- spinSettings . Add ( new {
19- position = "Top"
20- } ) ;
21- spinSettings . Add ( new {
22- position = "Bottom"
23- } ) ;
24- spinSettings . Add ( new {
25- position = "Center"
26- } ) ;
27- ViewBag . spinSettings = spinSettings ;
28- List < object > animationSettings = new List < object > ( ) ;
29- animationSettings . Add ( new {
30- effect = "SlideLeft"
31- } ) ;
32- animationSettings . Add ( new {
33- effect = "SlideRight"
34- } ) ;
35- animationSettings . Add ( new {
36- effect = "ZoomIn"
37- } ) ;
38- animationSettings . Add ( new {
39- effect = "ZoomOut"
40- } ) ;
41- ViewBag . animationSettings = animationSettings ;
14+ ProgressButtonSpinSettings spinRight = new ProgressButtonSpinSettings ( ) { Position = SpinPosition . Right } ;
15+ ProgressButtonSpinSettings spinTop = new ProgressButtonSpinSettings ( ) { Position = SpinPosition . Top } ;
16+ ProgressButtonSpinSettings spinBottom = new ProgressButtonSpinSettings ( ) { Position = SpinPosition . Bottom } ;
17+ ProgressButtonSpinSettings spinCenter = new ProgressButtonSpinSettings ( ) { Position = SpinPosition . Center } ;
18+
19+ ViewBag . spinRight = spinRight ;
20+ ViewBag . spinTop = spinTop ;
21+ ViewBag . spinBottom = spinBottom ;
22+ ViewBag . spinCenter = spinCenter ;
23+
24+ ProgressButtonAnimationSettings slideLeft = new ProgressButtonAnimationSettings ( ) { Effect = AnimationEffect . SlideLeft } ;
25+ ProgressButtonAnimationSettings slideRight = new ProgressButtonAnimationSettings ( ) { Effect = AnimationEffect . SlideRight } ;
26+ ProgressButtonAnimationSettings zoomIn = new ProgressButtonAnimationSettings ( ) { Effect = AnimationEffect . ZoomIn } ;
27+ ProgressButtonAnimationSettings zoomOut = new ProgressButtonAnimationSettings ( ) { Effect = AnimationEffect . ZoomOut } ;
28+
29+ ViewBag . slideLeft = slideLeft ;
30+ ViewBag . slideRight = slideRight ;
31+ ViewBag . zoomIn = zoomIn ;
32+ ViewBag . zoomOut = zoomOut ;
4233 return View ( ) ;
4334 }
4435 }
0 commit comments