wxxsw / SwiftTheme

🎨 Powerful theme/skin manager for iOS 9+ 主题/换肤, 暗色模式
MIT License
2.52k stars 305 forks source link

如何获取ThemePicker对应的值?ThemePicker.value() 为Optional<Any> #170

Closed HMWDavid closed 1 year ago

HMWDavid commented 1 year ago

使用 ThemePicker.value()获取对应的值时它的类型为Optional,当我转换为我想要的类型时始终为nil. ThemeColorPicker.value() as? String 始终为nil

HMWDavid commented 1 year ago
image
HMWDavid commented 1 year ago

其中 MThemePickers.Global.red 是 ThemeColorPicker类型

HMWDavid commented 1 year ago

已在此处找到解决方案: https://github.com/wxxsw/SwiftTheme/issues/122