[node] Add support for Image expression
This commit is contained in:
@@ -42,7 +42,8 @@ type::Type parseType(v8::Local<v8::Object> type) {
|
||||
{"color", type::Color},
|
||||
{"value", type::Value},
|
||||
{"formatted", type::Formatted},
|
||||
{"number-format", type::String}};
|
||||
{"number-format", type::String},
|
||||
{"resolvedImage", type::Image}};
|
||||
|
||||
v8::Local<v8::Value> v8kind = Nan::Get(type, Nan::New("kind").ToLocalChecked()).ToLocalChecked();
|
||||
std::string kind(*v8::String::Utf8Value(v8kind));
|
||||
@@ -220,6 +221,8 @@ struct ToValue {
|
||||
|
||||
return scope.Escape(result);
|
||||
}
|
||||
|
||||
v8::Local<v8::Value> operator()(const Image& image) { return toJS(image.toValue()); }
|
||||
};
|
||||
|
||||
v8::Local<v8::Value> toJS(const Value& value) {
|
||||
|
||||
Reference in New Issue
Block a user