From 3baf3d2545ba6ece6b74a64c0def59bd0774cf54 Mon Sep 17 00:00:00 2001
From: Jake Vanderwerf <get@jakevanderwerf.ca>
Date: Wed, 10 Jun 2026 16:34:12 +0000
Subject: [PATCH] =Laid the groundwork for an improved DashboardManager.php setup. Have to put it aside so I can get the dang Northeh done though.
---
inc/meta/MetaTypeManager.php | 23 +++++++++++++++++++++--
1 files changed, 21 insertions(+), 2 deletions(-)
diff --git a/inc/meta/MetaTypeManager.php b/inc/meta/MetaTypeManager.php
index 4ea0aeb..e0da68f 100644
--- a/inc/meta/MetaTypeManager.php
+++ b/inc/meta/MetaTypeManager.php
@@ -50,6 +50,11 @@
'sanitize' => 'sanitize_email',
'default' => '',
],
+ 'phone' => [
+ 'type' => 'string',
+ 'sanitize' => 'sanitizeTelephone',
+ 'default' => '',
+ ],
'url' => [
'type' => 'string',
'sanitize' => 'esc_url_raw',
@@ -80,12 +85,17 @@
'sanitize' => 'sanitizeUser',
'default' => '',
],
+ 'post' => [
+ 'type' => 'string',
+ 'sanitize' => 'sanitizePost',
+ 'default' => '',
+ ],
'repeater' => [
'type' => 'object',
'sanitize' => 'sanitizeRepeater',
'default' => [],
],
- 'tag_list' => [
+ 'taglist' => [
'type' => 'object',
'sanitize' => 'sanitizeTagList',
'default' => []
@@ -128,7 +138,12 @@
'type' => 'string',
'sanitize' => 'sanitize_text_field',
'default' => '',
- ]
+ ],
+ 'selector' => [
+ 'type' => 'string',
+ 'sanitize' => 'sanitizeSelector',
+ 'default' => '',
+ ]
];
public static function getType(string $field_name):array
{
@@ -149,4 +164,8 @@
{
static::$type_map[$type] = $config;
}
+ public static function getTypes():array
+ {
+ return static::$type_map;
+ }
}
--
Gitblit v1.10.0