예제 #1
0
        private UxNode BuildSymbolInstance(SketchSymbolInstance symbolInstance)
        {
            var className = _symbolClassNameBuilder.GetClassName(symbolInstance);
            var node      = new UxNode {
                ClassName       = className,
                SketchLayerName = symbolInstance.Name
            };

            return(BuildLayout(symbolInstance, node));
        }
예제 #2
0
 public string GetClassName(SketchSymbolInstance symbolInstance)
 {
     try
     {
         return(_symbolClasses[symbolInstance.SymbolId]);
     }
     catch (KeyNotFoundException)
     {
         throw new UxBuilderException("The symbol '" + symbolInstance.Name + "' is an instance of a symbol we can't find. Could it be that it's defined in another Sketch file? That is currently not supported. (SymbolId '" + symbolInstance.SymbolId + "')");
     }
 }