PluginProbe
The Innovative Form Builder – IvyForms / 1.5
The Innovative Form Builder – IvyForms v1.5
1.5.1 1.5 1.4.1 1.4 trunk 0.1.2 0.2 0.2.1 0.3 0.3.1 0.4 0.5 0.6 0.6.1 0.6.1-backup 0.6.1.1 0.7 0.8 0.8.1 0.8.2 0.9 0.9.1 1.0 1.1 1.1.1 All 27 releases
← All changes | backend/src/ValueObjects/Field/FieldGeneralSettings.php +64 -9 1.0 → 1.5 View file →
@@ -88,8 +88,12 @@
88 88 * @var float Step increment for number fields
89 89 */
90 90 public float $step;
91 91 /**
92 + * @var bool Show grid marks on slider
93 + */
94 + public bool $showGrid;
95 + /**
92 96 * @var string Number format key
93 97 */
94 98 public string $numberFormat;
95 99 /**
@@ -111,13 +115,17 @@
111 115 * Whether to show text labels alongside rating.
112 116 * @var bool
113 117 */
114 118 private bool $showRatingText;
115 - /**
119 + /**
116 120 * @var string HTML content for HTML field type
117 121 */
118 122 private string $htmlContent;
119 123 /**
124 + * @var string Agreement text for GDPR field type
125 + */
126 + private string $agreementText;
127 + /**
120 128 * @var bool
121 129 */
122 130 private bool $limitRange;
123 131
@@ -139,9 +147,11 @@
139 147 * @param bool $phoneAutoDetect
140 148 * @param float|null $minValue
141 149 * @param float|null $maxValue
142 150 * @param float $step
151 + * @param bool $showGrid
143 152 * @param string $numberFormat
153 + * @param ConfirmationGeneralSettings $confirmationSettings
144 154 * @param TimeFieldGeneralSettings $timeSettings
145 155 * @param DateFieldGeneralSettings $dateSettings
146 156 * @param bool $visible
147 157 * @param bool $showRatingText
@@ -168,8 +178,9 @@
168 178 bool $phoneAutoDetect,
169 179 ?float $minValue,
170 180 ?float $maxValue,
171 181 float $step,
182 + bool $showGrid,
172 183 string $numberFormat,
173 184 ConfirmationGeneralSettings $confirmationSettings,
174 185 TimeFieldGeneralSettings $timeSettings,
175 186 DateFieldGeneralSettings $dateSettings,
@@ -175,8 +186,9 @@
175 186 DateFieldGeneralSettings $dateSettings,
176 187 bool $showRatingText,
177 188 bool $visible = true,
178 189 string $htmlContent = '',
190 + string $agreementText = '',
179 191 bool $limitRange = false
180 192 ) {
181 193 $this->label = $label;
182 194 $this->required = $required;
@@ -193,15 +205,17 @@
193 205 $this->phoneAutoDetect = $phoneAutoDetect;
194 206 $this->minValue = $minValue;
195 207 $this->maxValue = $maxValue;
196 208 $this->step = $step;
209 + $this->showGrid = $showGrid;
197 210 $this->numberFormat = $numberFormat;
198 211 $this->visible = $visible;
199 212 $this->confirmationSettings = $confirmationSettings;
200 213 $this->timeSettings = $timeSettings;
201 214 $this->dateSettings = $dateSettings;
215 + $this->htmlContent = $htmlContent;
202 216 $this->showRatingText = $showRatingText;
203 - $this->htmlContent = $htmlContent;
217 + $this->agreementText = $agreementText;
204 218 $this->limitRange = $limitRange;
205 219 }
206 220
207 221 /**
@@ -438,8 +452,28 @@
438 452 $this->step = $step;
439 453 }
440 454
441 455 /**
456 + * Get the show grid value.
457 + *
458 + * @return bool
459 + */
460 + public function getShowGrid(): bool
461 + {
462 + return $this->showGrid;
463 + }
464 +
465 + /**
466 + * Set the show grid value.
467 + *
468 + * @param bool $showGrid
469 + */
470 + public function setShowGrid(bool $showGrid): void
471 + {
472 + $this->showGrid = $showGrid;
473 + }
474 +
475 + /**
442 476 * Get the number format.
443 477 *
444 478 * @return string
445 479 */
@@ -458,8 +492,27 @@
458 492 $this->numberFormat = $numberFormat;
459 493 }
460 494
461 495 /**
496 + * Get the HTML content.
497 + * @return string
498 + */
499 + public function getHtmlContent(): string
500 + {
501 + return $this->htmlContent;
502 + }
503 +
504 + /**
505 + * Set the HTML content.
506 + *
507 + * @param string $htmlContent
508 + */
509 + public function setHtmlContent(string $htmlContent): void
510 + {
511 + $this->htmlContent = $htmlContent;
512 + }
513 +
514 + /**
462 515 * Get showRatingText flag.
463 516 * @return bool
464 517 */
465 518 public function isShowRatingText(): bool
@@ -477,24 +530,24 @@
477 530 $this->showRatingText = (bool)$val;
478 531 }
479 532
480 533 /**
481 - * Get the HTML content.
534 + * Get the agreement text.
482 535 * @return string
483 536 */
484 - public function getHtmlContent(): string
537 + public function getAgreementText(): string
485 538 {
486 - return $this->htmlContent;
539 + return $this->agreementText;
487 540 }
488 541
489 542 /**
490 - * Set the HTML content.
543 + * Set the agreement text.
491 544 *
492 - * @param string $htmlContent
545 + * @param string $agreementText
493 546 */
494 - public function setHtmlContent(string $htmlContent): void
547 + public function setAgreementText(string $agreementText): void
495 548 {
496 - $this->htmlContent = $htmlContent;
549 + $this->agreementText = $agreementText;
497 550 }
498 551
499 552 /**
500 553 * Get limitRange.
@@ -536,12 +589,14 @@
536 589 'phoneAutoDetect' => $this->isPhoneAutoDetect(),
537 590 'minValue' => $this->getMinValue(),
538 591 'maxValue' => $this->getMaxValue(),
539 592 'step' => $this->getStep(),
593 + 'showGrid' => $this->getShowGrid(),
540 594 'numberFormat' => $this->getNumberFormat(),
541 595 'visible' => $this->isVisible(),
542 596 'showRatingText' => $this->isShowRatingText(),
543 597 'htmlContent' => $this->getHtmlContent(),
598 + 'agreementText' => $this->getAgreementText(),
544 599 'limitRange' => $this->isLimitRange(),
545 600 ],
546 601 $this->confirmationSettings->toArray(),
547 602 $this->timeSettings->toArray(),