Loading editor/widgets/button/button.cpp +36 −1 Changes for editor/widgets/button/button.cpp: 36 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -382,7 +382,7 @@ extern "C" { json_object_object_add(hf, "default", json_object_new_boolean(false)); } addField("hover_effect", "Hover Effect", "select", nullptr, "desktop", mkOpts({"none","move_up","glow","scale","fade","move_up_glow"})); mkOpts({"none","move_up","glow","scale","fade","move_up_glow","pulse","shake","bounce","shimmer"})); addField("hover_bg_color", "Hover Background Color", "color_var", nullptr, "desktop"); addField("hover_text_color", "Hover Text Color", "color_var", nullptr, "desktop"); addField("hover_transition", "Hover Transition", "text", "0.2s ease", "desktop"); Loading Loading @@ -831,6 +831,40 @@ extern "C" { // Hover effect CSS std::string hoverCSS; if (hoverEffect != "none") { std::string glowColor = hoverBgColor.empty() ? backgroundColor : hoverBgColor; std::string animName = "we_" + hoverEffect + "_" + std::string(getInstanceId()); if (hoverEffect == "pulse") { hoverCSS = "@keyframes " + animName + "{ 0%,100%{ box-shadow:0 0 8px 2px " + glowColor + "; } 50%{ box-shadow:0 0 22px 7px " + glowColor + "; } } "; hoverCSS += "." + responsiveClass + ":hover { animation:" + animName + " 1.2s ease infinite;"; if (!hoverBgColor.empty()) hoverCSS += " background-color:" + hoverBgColor + " !important;"; if (!hoverTextColor.empty()) hoverCSS += " color:" + hoverTextColor + " !important;"; hoverCSS += " }"; } else if (hoverEffect == "shake") { hoverCSS = "@keyframes " + animName + "{ 0%,100%{ transform:translateX(0); } 20%{ transform:translateX(-6px); } 40%{ transform:translateX(6px); } 60%{ transform:translateX(-4px); } 80%{ transform:translateX(4px); } } "; hoverCSS += "." + responsiveClass + ":hover { animation:" + animName + " 0.5s ease;"; if (!hoverBgColor.empty()) hoverCSS += " background-color:" + hoverBgColor + " !important;"; if (!hoverTextColor.empty()) hoverCSS += " color:" + hoverTextColor + " !important;"; hoverCSS += " }"; } else if (hoverEffect == "bounce") { hoverCSS = "@keyframes " + animName + "{ 0%,100%{ transform:translateY(0); } 40%{ transform:translateY(-10px); } 70%{ transform:translateY(-5px); } } "; hoverCSS += "." + responsiveClass + ":hover { animation:" + animName + " 0.6s ease;"; if (!hoverBgColor.empty()) hoverCSS += " background-color:" + hoverBgColor + " !important;"; if (!hoverTextColor.empty()) hoverCSS += " color:" + hoverTextColor + " !important;"; hoverCSS += " }"; } else if (hoverEffect == "shimmer") { hoverCSS = "." + responsiveClass + "{ position:relative; overflow:hidden; } "; hoverCSS += "@keyframes " + animName + "{ 0%{ left:-100%; } 100%{ left:200%; } } "; hoverCSS += "." + responsiveClass + "::before{ content:''; position:absolute; top:0; left:-100%; width:60%; height:100%; background:linear-gradient(120deg,transparent 20%,rgba(255,255,255,0.4) 50%,transparent 80%); } "; hoverCSS += "." + responsiveClass + ":hover::before{ animation:" + animName + " 0.7s ease; }"; if (!hoverBgColor.empty() || !hoverTextColor.empty()) { hoverCSS += " ." + responsiveClass + ":hover {"; if (!hoverBgColor.empty()) hoverCSS += " background-color:" + hoverBgColor + " !important;"; if (!hoverTextColor.empty()) hoverCSS += " color:" + hoverTextColor + " !important;"; hoverCSS += " }"; } } else { // Static effects: move_up, glow, scale, fade, move_up_glow std::string hoverProps; if (hoverEffect == "move_up" || hoverEffect == "move_up_glow") hoverProps += " transform: translateY(-4px);"; Loading @@ -847,6 +881,7 @@ extern "C" { if (!hoverProps.empty()) hoverCSS = "." + responsiveClass + ":hover {" + hoverProps + " }"; } } std::string allMediaCSS; if (!hoverCSS.empty()) Loading editor/widgets/textbox/textbox.cpp +12 −0 Changes for editor/widgets/textbox/textbox.cpp: 12 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -72,6 +72,7 @@ extern "C" { std::string fontStyle = "normal"; std::string whiteSpace = "normal"; std::string textDecoration = "none"; std::string underlineColor = ""; // Icon std::string icon = "none"; Loading Loading @@ -269,6 +270,7 @@ extern "C" { addField("font_style", "Font Style", "select", nullptr, "all", mkOpts({"normal","italic","oblique"})); addField("white_space", "Zeilenumbruch", "select", nullptr, "all", mkOpts({"normal","nowrap","pre","pre-wrap","pre-line","break-spaces"})); addField("text_decoration", "Text Decoration", "select", nullptr, "all", mkOpts({"none","underline","overline","line-through","underline overline"})); addField("underline_color", "Underline Color", "color_var", nullptr, "all"); addField("icon", "Icon", "select", nullptr, "all", mkOpts({"none","phone","address","email","arrow_left","arrow_right","arrow_up","arrow_down"})); addField("icon_color", "Icon Color", "color_var", nullptr, "all"); addField("hidden", "Hidden", "checkbox", nullptr, "desktop"); Loading Loading @@ -304,6 +306,7 @@ extern "C" { element->SetAttribute("font_style", fontStyle.c_str()); element->SetAttribute("white_space", whiteSpace.c_str()); element->SetAttribute("text_decoration", textDecoration.c_str()); element->SetAttribute("underline_color", underlineColor.c_str()); element->SetAttribute("icon", icon.c_str()); element->SetAttribute("icon_color", iconColor.c_str()); Loading Loading @@ -369,6 +372,9 @@ extern "C" { val = xml_data->Attribute("text_decoration"); if (val) textDecoration = val; val = xml_data->Attribute("underline_color"); if (val) underlineColor = val; val = xml_data->Attribute("icon"); if (val) icon = val; Loading Loading @@ -424,6 +430,7 @@ extern "C" { json_object_object_add(obj, "font_style", json_object_new_string(fontStyle.c_str())); json_object_object_add(obj, "white_space", json_object_new_string(whiteSpace.c_str())); json_object_object_add(obj, "text_decoration", json_object_new_string(textDecoration.c_str())); json_object_object_add(obj, "underline_color", json_object_new_string(underlineColor.c_str())); json_object_object_add(obj, "icon", json_object_new_string(icon.c_str())); json_object_object_add(obj, "icon_color", json_object_new_string(iconColor.c_str())); json_object_object_add(obj, "width", json_object_new_string(width.c_str())); Loading Loading @@ -485,6 +492,10 @@ extern "C" { val = json_object_get_string(val_obj); if (val) textDecoration = val; } if (json_object_object_get_ex(obj, "underline_color", &val_obj)) { val = json_object_get_string(val_obj); if (val) underlineColor = val; } if (json_object_object_get_ex(obj, "icon", &val_obj)) { val = json_object_get_string(val_obj); if (val) icon = val; Loading Loading @@ -570,6 +581,7 @@ extern "C" { if (fontStyle != "normal") style += " font-style: " + fontStyle + ";"; if (whiteSpace != "normal") style += " white-space: " + whiteSpace + ";"; if (textDecoration != "none" && !textDecoration.empty()) style += " text-decoration: " + textDecoration + ";"; if (!underlineColor.empty()) style += " text-decoration-color: " + underlineColor + ";"; if (hidden) style += " display: none;"; box.setAttribute("style", style.c_str()); Loading Loading
editor/widgets/button/button.cpp +36 −1 Changes for editor/widgets/button/button.cpp: 36 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -382,7 +382,7 @@ extern "C" { json_object_object_add(hf, "default", json_object_new_boolean(false)); } addField("hover_effect", "Hover Effect", "select", nullptr, "desktop", mkOpts({"none","move_up","glow","scale","fade","move_up_glow"})); mkOpts({"none","move_up","glow","scale","fade","move_up_glow","pulse","shake","bounce","shimmer"})); addField("hover_bg_color", "Hover Background Color", "color_var", nullptr, "desktop"); addField("hover_text_color", "Hover Text Color", "color_var", nullptr, "desktop"); addField("hover_transition", "Hover Transition", "text", "0.2s ease", "desktop"); Loading Loading @@ -831,6 +831,40 @@ extern "C" { // Hover effect CSS std::string hoverCSS; if (hoverEffect != "none") { std::string glowColor = hoverBgColor.empty() ? backgroundColor : hoverBgColor; std::string animName = "we_" + hoverEffect + "_" + std::string(getInstanceId()); if (hoverEffect == "pulse") { hoverCSS = "@keyframes " + animName + "{ 0%,100%{ box-shadow:0 0 8px 2px " + glowColor + "; } 50%{ box-shadow:0 0 22px 7px " + glowColor + "; } } "; hoverCSS += "." + responsiveClass + ":hover { animation:" + animName + " 1.2s ease infinite;"; if (!hoverBgColor.empty()) hoverCSS += " background-color:" + hoverBgColor + " !important;"; if (!hoverTextColor.empty()) hoverCSS += " color:" + hoverTextColor + " !important;"; hoverCSS += " }"; } else if (hoverEffect == "shake") { hoverCSS = "@keyframes " + animName + "{ 0%,100%{ transform:translateX(0); } 20%{ transform:translateX(-6px); } 40%{ transform:translateX(6px); } 60%{ transform:translateX(-4px); } 80%{ transform:translateX(4px); } } "; hoverCSS += "." + responsiveClass + ":hover { animation:" + animName + " 0.5s ease;"; if (!hoverBgColor.empty()) hoverCSS += " background-color:" + hoverBgColor + " !important;"; if (!hoverTextColor.empty()) hoverCSS += " color:" + hoverTextColor + " !important;"; hoverCSS += " }"; } else if (hoverEffect == "bounce") { hoverCSS = "@keyframes " + animName + "{ 0%,100%{ transform:translateY(0); } 40%{ transform:translateY(-10px); } 70%{ transform:translateY(-5px); } } "; hoverCSS += "." + responsiveClass + ":hover { animation:" + animName + " 0.6s ease;"; if (!hoverBgColor.empty()) hoverCSS += " background-color:" + hoverBgColor + " !important;"; if (!hoverTextColor.empty()) hoverCSS += " color:" + hoverTextColor + " !important;"; hoverCSS += " }"; } else if (hoverEffect == "shimmer") { hoverCSS = "." + responsiveClass + "{ position:relative; overflow:hidden; } "; hoverCSS += "@keyframes " + animName + "{ 0%{ left:-100%; } 100%{ left:200%; } } "; hoverCSS += "." + responsiveClass + "::before{ content:''; position:absolute; top:0; left:-100%; width:60%; height:100%; background:linear-gradient(120deg,transparent 20%,rgba(255,255,255,0.4) 50%,transparent 80%); } "; hoverCSS += "." + responsiveClass + ":hover::before{ animation:" + animName + " 0.7s ease; }"; if (!hoverBgColor.empty() || !hoverTextColor.empty()) { hoverCSS += " ." + responsiveClass + ":hover {"; if (!hoverBgColor.empty()) hoverCSS += " background-color:" + hoverBgColor + " !important;"; if (!hoverTextColor.empty()) hoverCSS += " color:" + hoverTextColor + " !important;"; hoverCSS += " }"; } } else { // Static effects: move_up, glow, scale, fade, move_up_glow std::string hoverProps; if (hoverEffect == "move_up" || hoverEffect == "move_up_glow") hoverProps += " transform: translateY(-4px);"; Loading @@ -847,6 +881,7 @@ extern "C" { if (!hoverProps.empty()) hoverCSS = "." + responsiveClass + ":hover {" + hoverProps + " }"; } } std::string allMediaCSS; if (!hoverCSS.empty()) Loading
editor/widgets/textbox/textbox.cpp +12 −0 Changes for editor/widgets/textbox/textbox.cpp: 12 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -72,6 +72,7 @@ extern "C" { std::string fontStyle = "normal"; std::string whiteSpace = "normal"; std::string textDecoration = "none"; std::string underlineColor = ""; // Icon std::string icon = "none"; Loading Loading @@ -269,6 +270,7 @@ extern "C" { addField("font_style", "Font Style", "select", nullptr, "all", mkOpts({"normal","italic","oblique"})); addField("white_space", "Zeilenumbruch", "select", nullptr, "all", mkOpts({"normal","nowrap","pre","pre-wrap","pre-line","break-spaces"})); addField("text_decoration", "Text Decoration", "select", nullptr, "all", mkOpts({"none","underline","overline","line-through","underline overline"})); addField("underline_color", "Underline Color", "color_var", nullptr, "all"); addField("icon", "Icon", "select", nullptr, "all", mkOpts({"none","phone","address","email","arrow_left","arrow_right","arrow_up","arrow_down"})); addField("icon_color", "Icon Color", "color_var", nullptr, "all"); addField("hidden", "Hidden", "checkbox", nullptr, "desktop"); Loading Loading @@ -304,6 +306,7 @@ extern "C" { element->SetAttribute("font_style", fontStyle.c_str()); element->SetAttribute("white_space", whiteSpace.c_str()); element->SetAttribute("text_decoration", textDecoration.c_str()); element->SetAttribute("underline_color", underlineColor.c_str()); element->SetAttribute("icon", icon.c_str()); element->SetAttribute("icon_color", iconColor.c_str()); Loading Loading @@ -369,6 +372,9 @@ extern "C" { val = xml_data->Attribute("text_decoration"); if (val) textDecoration = val; val = xml_data->Attribute("underline_color"); if (val) underlineColor = val; val = xml_data->Attribute("icon"); if (val) icon = val; Loading Loading @@ -424,6 +430,7 @@ extern "C" { json_object_object_add(obj, "font_style", json_object_new_string(fontStyle.c_str())); json_object_object_add(obj, "white_space", json_object_new_string(whiteSpace.c_str())); json_object_object_add(obj, "text_decoration", json_object_new_string(textDecoration.c_str())); json_object_object_add(obj, "underline_color", json_object_new_string(underlineColor.c_str())); json_object_object_add(obj, "icon", json_object_new_string(icon.c_str())); json_object_object_add(obj, "icon_color", json_object_new_string(iconColor.c_str())); json_object_object_add(obj, "width", json_object_new_string(width.c_str())); Loading Loading @@ -485,6 +492,10 @@ extern "C" { val = json_object_get_string(val_obj); if (val) textDecoration = val; } if (json_object_object_get_ex(obj, "underline_color", &val_obj)) { val = json_object_get_string(val_obj); if (val) underlineColor = val; } if (json_object_object_get_ex(obj, "icon", &val_obj)) { val = json_object_get_string(val_obj); if (val) icon = val; Loading Loading @@ -570,6 +581,7 @@ extern "C" { if (fontStyle != "normal") style += " font-style: " + fontStyle + ";"; if (whiteSpace != "normal") style += " white-space: " + whiteSpace + ";"; if (textDecoration != "none" && !textDecoration.empty()) style += " text-decoration: " + textDecoration + ";"; if (!underlineColor.empty()) style += " text-decoration-color: " + underlineColor + ";"; if (hidden) style += " display: none;"; box.setAttribute("style", style.c_str()); Loading