Explorar o código

add more validator

weichen %!s(int64=3) %!d(string=hai) anos
pai
achega
b393af059c
Modificáronse 1 ficheiros con 10 adicións e 0 borrados
  1. 10 0
      models/utils/validators.py

+ 10 - 0
models/utils/validators.py

@@ -6,6 +6,10 @@ def is_valid_section3_section(text):
     return 'class="section3"' in text
 
 
+def is_valid_section3_text_center_section(text):
+    return 'class="section3 text-center"' in text
+
+
 def is_valid_section13_overly_section(text):
     return 'class="section13 overly"' in text
 
@@ -14,6 +18,10 @@ def is_valid_section14_section(text):
     return 'class="section14"' in text
 
 
+def is_valid_section14_d_flex_section(text):
+    return 'class="section14 d-flex align-items-center"' in text
+
+
 def is_valid_section13_section(text):
     return 'class="section13"' in text
 
@@ -63,9 +71,11 @@ def unvalid_section(text):
 
 
 IS_VALID_SECTION = {'section3': is_valid_section3_section,
+                    'section3_text-center': is_valid_section3_text_center_section,
                     'section13_overly': is_valid_section13_overly_section,
                     'section13': is_valid_section13_section,
                     'section14': is_valid_section14_section,
+                    'section14_d-flex_align-items-center': is_valid_section14_d_flex_section,
                     'section16': is_valid_section16_section,
                     'section17': is_valid_section17_section,
                     'section18': is_valid_section18_section,