コード例 #1
0
        private void BuildDialogClasses(ClassBuilder builder)
        {
            builder.Append("ant-modal");
            builder.Append($"ant-modal-{ClassProvider.ToModalSize( Size )}");

            if (Fullscreen)
            {
                builder.Append("ant-modal-fullscreen");
            }
        }
コード例 #2
0
        private void BuildNumericWrapperClasses(ClassBuilder builder)
        {
            builder.Append("b-numeric");
            builder.Append(ClassProvider.NumericPickerValidation(ParentValidation?.Status ?? ValidationStatus.None), ParentValidation?.Status != ValidationStatus.None);

            if (numericWrapperWidth != null)
            {
                builder.Append(numericWrapperWidth.Class(ClassProvider));
            }
        }
コード例 #3
0
ファイル: BaseButtons.cs プロジェクト: tonyhawe/Blazorise
        protected override void RegisterClasses()
        {
            ClassMapper
            .If(() => ClassProvider.ButtonsAddons(), () => Role == ButtonsRole.Addons)
            .If(() => ClassProvider.ButtonsToolbar(), () => Role == ButtonsRole.Toolbar)
            .If(() => ClassProvider.ButtonsVertical(), () => Orientation == Orientation.Vertical)
            .If(() => ClassProvider.ButtonsSize(Size), () => Size != Size.None);

            base.RegisterClasses();
        }
コード例 #4
0
ファイル: Field.razor.cs プロジェクト: yorytang/Blazorise
        protected override void BuildClasses(ClassBuilder builder)
        {
            if (!IsFields && ColumnSize != null)
            {
                builder.Append(ClassProvider.FieldColumn());
                builder.Append(ColumnSize.Class(ClassProvider));
            }

            base.BuildClasses(builder);
        }
コード例 #5
0
ファイル: BasePagination.cs プロジェクト: tesm/Blazorise
        protected override void RegisterClasses()
        {
            ClassMapper
            .Add(() => ClassProvider.Pagination())
            .If(() => ClassProvider.PaginationSize(Size), () => Size != Size.None)
            .If(() => ClassProvider.FlexAlignment(Alignment), () => Alignment != Alignment.None)
            .If(() => ClassProvider.BackgroundColor(Background), () => Background != Background.None);

            base.RegisterClasses();
        }
コード例 #6
0
        protected override void RegisterClasses()
        {
            ClassMapper
            .If(() => ClassProvider.Radio(), () => RadioGroup != null)
            .If(() => ClassProvider.Check(), () => RadioGroup == null)
            .If(() => ClassProvider.CheckCursor(Cursor), () => Cursor != Cursor.Default)
            .If(() => ClassProvider.CheckValidation(ParentValidation?.Status ?? ValidationStatus.None), () => ParentValidation?.Status != ValidationStatus.None);

            base.RegisterClasses();
        }
コード例 #7
0
        protected override void RegisterClasses()
        {
            ClassMapper
            .Add(() => ClassProvider.TableRowCell())
            .If(() => ClassProvider.TableRowCellColor(Color), () => Color != Color.None)
            .If(() => ClassProvider.TableRowCellBackground(Background), () => Background != Background.None)
            .If(() => ClassProvider.TableRowCellTextColor(TextColor), () => TextColor != TextColor.None);

            base.RegisterClasses();
        }
コード例 #8
0
ファイル: BaseTable.cs プロジェクト: tonyhawe/Blazorise
        protected override void RegisterClasses()
        {
            ClassMapper
            .Add(() => ClassProvider.Table())
            .If(() => ClassProvider.TableFullWidth(), () => IsFullWidth)
            .If(() => ClassProvider.TableStriped(), () => IsStriped)
            .If(() => ClassProvider.TableBordered(), () => IsBordered)
            .If(() => ClassProvider.TableHoverable(), () => IsHoverable);

            base.RegisterClasses();
        }
コード例 #9
0
ファイル: BaseBarItem.cs プロジェクト: EnhWeb/DC.Blazor
        protected override void RegisterClasses()
        {
            ClassMapper
            .Add(() => ClassProvider.BarItem())
            .If(() => ClassProvider.BarItemActive(), () => IsActive)
            .If(() => ClassProvider.BarItemDisabled(), () => IsDisabled)
            .If(() => ClassProvider.BarItemHasDropdown(), () => IsDropdown)
            .If(() => ClassProvider.BarItemHasDropdownShow(), () => IsDropdown && barDropdown?.IsOpen == true);

            base.RegisterClasses();
        }
コード例 #10
0
        protected override void RegisterClasses()
        {
            ClassMapper
            .Add(() => ClassProvider.ProgressBar())
            .Add(() => ClassProvider.ProgressBarWidth(Value ?? 0))
            .If(() => ClassProvider.BackgroundColor(Background), () => Background != Background.None)
            .If(() => ClassProvider.ProgressBarStriped(), () => IsStriped)
            .If(() => ClassProvider.ProgressBarAnimated(), () => IsAnimated);

            base.RegisterClasses();
        }
コード例 #11
0
        protected override void RegisterClasses()
        {
            ClassMapper
            .Add(() => ClassProvider.Alert())
            .If(() => ClassProvider.AlertColor(Color), () => Color != Color.None)
            .If(() => ClassProvider.AlertDismisable(), () => IsDismisable)
            .If(() => ClassProvider.Fade(), () => IsDismisable)
            .If(() => ClassProvider.Show(), () => IsDismisable && IsShow);

            base.RegisterClasses();
        }
コード例 #12
0
ファイル: BaseDropdownToggle.cs プロジェクト: tesm/Blazorise
        protected override void RegisterClasses()
        {
            ClassMapper
            .Add(() => ClassProvider.DropdownToggle())
            .If(() => ClassProvider.DropdownToggleColor(Color), () => Color != Color.None && !IsOutline)
            .If(() => ClassProvider.DropdownToggleOutline(Color), () => Color != Color.None && IsOutline)
            .If(() => ClassProvider.DropdownToggleSize(Size), () => Size != ButtonSize.None)
            .If(() => ClassProvider.DropdownToggleSplit(), () => IsSplit);

            base.RegisterClasses();
        }
コード例 #13
0
ファイル: BaseSimpleText.cs プロジェクト: tesm/Blazorise
        protected override void RegisterClasses()
        {
            ClassMapper
            .If(() => ClassProvider.SimpleTextColor(Color), () => Color != TextColor.None)
            .If(() => ClassProvider.SimpleTextAlignment(Alignment), () => Alignment != TextAlignment.None)
            .If(() => ClassProvider.SimpleTextTransform(Transform), () => Transform != TextTransform.None)
            .If(() => ClassProvider.SimpleTextWeight(Weight), () => Weight != TextWeight.None)
            .If(() => ClassProvider.SimpleTextItalic(), () => IsItalic);

            base.RegisterClasses();
        }
コード例 #14
0
        protected override void RegisterClasses()
        {
            ClassMapper
            .Add(() => ClassProvider.Dropdown())
            .If(() => ClassProvider.DropdownGroup(), () => IsGroup)
            .If(() => ClassProvider.DropdownShow(), () => IsOpen)
            .If(() => ClassProvider.DropdownRight(), () => IsRightAligned)
            .If(() => ClassProvider.DropdownDirection(Direction), () => Direction != Direction.Down);

            base.RegisterClasses();
        }
コード例 #15
0
        /// <summary>
        /// 加载模块。
        /// </summary>
        /// <param name="name"></param>
        /// <param name="assemmby"></param>
        /// <param name="type"></param>
        /// <returns></returns>
        static object LoadModule(string name, string assemmby, string type)
        {
            object module = ClassProvider.GetObjectInstance(assemmby, type);

            if (module == null)
            {
                throw new System.Exception("无法加载“" + name + "”,请通知您的系统管理人员。");
            }

            return(module);
        }
コード例 #16
0
        protected override void RegisterClasses()
        {
            ClassMapper
            .Add(() => ClassProvider.Bar())
            .If(() => ClassProvider.BackgroundColor(Background), () => Background != Background.None)
            .If(() => ClassProvider.BarShade(Theme), () => Theme != Theme.None)
            .If(() => ClassProvider.BarBreakpoint(Breakpoint), () => Breakpoint != Breakpoint.None)
            .If(() => ClassProvider.FlexAlignment(Alignment), () => Alignment != Alignment.None);

            base.RegisterClasses();
        }
コード例 #17
0
ファイル: BaseControl.cs プロジェクト: tesm/Blazorise
        protected override void RegisterClasses()
        {
            ClassMapper
            .If(() => ClassProvider.ControlCheck(), () => Role == ControlRole.Check)
            .If(() => ClassProvider.ControlRadio(), () => Role == ControlRole.Radio)
            .If(() => ClassProvider.ControlFile(), () => Role == ControlRole.File)
            .If(() => ClassProvider.ControlText(), () => Role == ControlRole.Text)
            .If(() => ClassProvider.CheckInline(), () => IsInline);

            base.RegisterClasses();
        }
コード例 #18
0
        protected override void BuildClasses(ClassBuilder builder)
        {
            builder.Append($"{ClassProvider.Spacing( Spacing.Padding, SpacingSize.Is1, Side.All, Breakpoint.None )} cursor-pointer");

            if (Selected)
            {
                builder.Append($"{ClassProvider.BackgroundColor( Background.Primary )} {ClassProvider.TextColor( TextColor.White )}");
            }

            base.BuildClasses(builder);
        }
コード例 #19
0
        public static void PopulateAllClasses(ClassProvider classProvider, DropDownList dropdown, bool addEmptyOption = false)
        {
            dropdown.DataSource     = classProvider.GetAllClasses();
            dropdown.DataTextField  = "Name";
            dropdown.DataValueField = "ID";
            dropdown.DataBind();

            if (addEmptyOption)
            {
                dropdown.Items.Insert(0, String.Empty);
            }
        }
コード例 #20
0
        protected override void RegisterClasses()
        {
            ClassMapper
            .Add(() => ClassProvider.Nav())
            .If(() => ClassProvider.NavTabs(), () => IsTabs)
            .If(() => ClassProvider.NavCards(), () => IsCards)
            .If(() => ClassProvider.NavPills(), () => IsPills)
            .If(() => ClassProvider.NavVertical(), () => IsVertical)
            .If(() => ClassProvider.NavFill(Fill), () => Fill != NavFillType.None);

            base.RegisterClasses();
        }
コード例 #21
0
 public void storeNewClass(
     string prefix,
     int year,
     string suffix
     )
 {
     ClassProvider.createClass(
         prefix,
         year,
         suffix
         );
 }
コード例 #22
0
        private void Register(IServiceCollection services)
        {
            IClassProvider classProvider = new ClassProvider();

            services.AddSingleton(classProvider);
            classProvider.Register(typeof(DomainInitializer), typeof(InfrastructureInitializer), typeof(IRepository));
            classProvider.Register(typeof(DomainInitializer), typeof(InfrastructureInitializer), typeof(IService));
            foreach (var item in classProvider.RegisteredClassDictionary)
            {
                services.AddSingleton(item.Key, item.Value);
            }
        }
コード例 #23
0
        public static void PopulatePaidClasses(ClassProvider classProvider, RadDropDownList dropdown, bool addEmptyOption = false)
        {
            dropdown.DataSource     = classProvider.GetAllClasses().Where(cls => cls.IsPaid);
            dropdown.DataTextField  = "Name";
            dropdown.DataValueField = "ID";
            dropdown.DataBind();

            if (addEmptyOption)
            {
                dropdown.Items.Insert(0, new DropDownListItem(String.Empty));
            }
        }
コード例 #24
0
        protected override void RegisterClasses()
        {
            ClassMapper
            .Add(() => ClassProvider.TabItem())
            .If(() => ClassProvider.TabItemActive(), () => IsActive);

            LinkClassMapper
            .Add(() => ClassProvider.TabLink())
            .If(() => ClassProvider.TabLinkActive(), () => IsActive);

            base.RegisterClasses();
        }
コード例 #25
0
ファイル: BaseTabs.cs プロジェクト: EnhWeb/DC.Blazor
        protected override void RegisterClasses()
        {
            ClassMapper
            .Add(() => ClassProvider.Tabs())
            .If(() => ClassProvider.TabsCards(), () => IsCards)
            .If(() => ClassProvider.TabsPills(), () => IsPills)
            .If(() => ClassProvider.TabsFullWidth(), () => IsFullWidth)
            .If(() => ClassProvider.TabsJustified(), () => IsJustified)
            .If(() => ClassProvider.TabsVertical(), () => IsVertical);

            base.RegisterClasses();
        }
コード例 #26
0
ファイル: BaseDropdownMenu.cs プロジェクト: EnhWeb/DC.Blazor
        protected override void RegisterClasses()
        {
            ClassMapper
            .Add(() => ClassProvider.DropdownMenu())
            .If(() => ClassProvider.DropdownMenuShow(), () => IsOpen)
            .If(() => ClassProvider.DropdownMenuRight(), () => IsRightAligned);

            BodyClassMapper
            .Add(() => ClassProvider.DropdownMenuBody());

            base.RegisterClasses();
        }
コード例 #27
0
        internal void updateSubscriptions()
        {
            cbClass.DataSource    = ClassProvider.getClassesBySportsFestival(m_SportsFestivalRef);
            cbClass.ValueMember   = "classId";
            cbClass.DisplayMember = "classId";
            cbClass.SelectedItem  = null;

            /*
             * cbStudent.DataSource = StudentProvider.getStudentsBySportsFestival(curSportsFestival);
             * cbStudent.ValueMember = "studentId";
             * cbStudent.SelectedItem = null;
             */
        }
コード例 #28
0
		public void SetGetRuntimeValue ()
		{
			object obj;
			string st = string.Empty;
			ClassProvider cp = new ClassProvider ();
			ActivityBind ab = new ActivityBind ("ClassProvider", "Name");

			obj = ab.GetRuntimeValue (cp, st.GetType ());
			Assert.AreEqual ("Hello", obj.ToString (), "C1#1");
			ab.SetRuntimeValue (cp, "Bye");

			obj = ab.GetRuntimeValue (cp, st.GetType ());
			Assert.AreEqual ("Bye", obj.ToString (), "C1#2");		
		}
コード例 #29
0
    public static void PopulatePaidClasses(DropDownList dropdown, bool addEmptyOption = false)
    {
        ClassProvider classProvider = UnityContainerHelper.Container.Resolve <ClassProvider>();

        dropdown.DataSource     = classProvider.GetAllClasses().Where(cls => cls.IsPaid);
        dropdown.DataTextField  = "Name";
        dropdown.DataValueField = "ID";
        dropdown.DataBind();

        if (addEmptyOption)
        {
            dropdown.Items.Insert(0, String.Empty);
        }
    }
コード例 #30
0
        public void SetGetRuntimeValue()
        {
            object        obj;
            string        st = string.Empty;
            ClassProvider cp = new ClassProvider();
            ActivityBind  ab = new ActivityBind("ClassProvider", "Name");

            obj = ab.GetRuntimeValue(cp, st.GetType());
            Assert.AreEqual("Hello", obj.ToString(), "C1#1");
            ab.SetRuntimeValue(cp, "Bye");

            obj = ab.GetRuntimeValue(cp, st.GetType());
            Assert.AreEqual("Bye", obj.ToString(), "C1#2");
        }
コード例 #31
0
        protected override void BuildClasses(ClassBuilder builder)
        {
            builder.Append($"{ClassProvider.Spacing( Spacing.Padding, SpacingSize.Is1, Side.All, Breakpoint.None )} cursor-pointer");

            if (Selected)
            {
                builder.Append($"{ClassProvider.BackgroundColor( selectedNodeStyling.Background )} {ClassProvider.TextColor( selectedNodeStyling.TextColor )} {selectedNodeStyling.Class}");
            }
            else
            {
                builder.Append($"{ClassProvider.BackgroundColor( nodeStyling.Background )} {ClassProvider.TextColor( nodeStyling.TextColor )} {nodeStyling.Class}");
            }

            base.BuildClasses(builder);
        }