Changeset 6155
- Timestamp:
- 11/21/2017 07:55:22 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/style/wp4.css
r6016 r6155 281 281 text-shadow: none !important; 282 282 border: none; 283 box-shadow: none; 283 284 height: 30px; 284 285 width: 26px; … … 676 677 } 677 678 678 /* New button styles 679 /* WordPress-style Buttons 680 ======================= 681 Create a button by adding the `.button` class to an element. For backwards 682 compatibility, we support several other classes (such as `.button-secondary`), 683 but these will *not* work with the stackable classes described below. 684 685 Button Styles 686 ------------- 687 To display a primary button style, add the `.button-primary` class to a button. 688 689 Button Sizes 690 ------------ 691 Adjust a button's size by adding the `.button-large` or `.button-small` class. 692 693 Button States 694 ------------- 695 Lock the state of a button by adding the name of the pseudoclass as 696 an actual class (e.g. `.hover` for `:hover`). 697 679 698 680 699 TABLE OF CONTENTS: … … 683 702 2.0 - Default Button Style 684 703 3.0 - Primary Button Style 704 4.0 - Button Groups 705 5.0 - Responsive Button Styles 685 706 686 707 ---------------------------------------------------------------------------- */ 687 688 /* 1.0 - Button Layouts */ 689 708 /* ---------------------------------------------------------------------------- 709 1.0 - Button Layouts 710 ---------------------------------------------------------------------------- */ 690 711 .submit input, 691 712 input[type=button], … … 695 716 .download-button, 696 717 .button-secondary { 697 display: inline-block; 698 text-decoration: none; 699 font-size: 12px; 700 line-height: 23px; 701 height: 24px; 702 margin: 0; 703 padding: 0 10px 1px; 704 cursor: pointer; 705 border-width: 1px; 706 border-style: solid; 718 border: 1px solid; 707 719 -webkit-border-radius: 3px; 708 -webkit-appearance: none;709 720 border-radius: 3px; 710 white-space: nowrap;711 721 -webkit-box-sizing: border-box; 712 722 -moz-box-sizing: border-box; 713 723 box-sizing: border-box; 724 cursor: pointer; 725 display: inline-block; 726 font-size: 0.8rem; 727 height: 1.5625rem; 728 line-height: 1; 729 margin: 0; 730 padding: 0 .8rem; 731 text-decoration: none; 732 white-space: nowrap; 733 -webkit-appearance: none; 714 734 } 715 735 … … 719 739 input[type="button"]::-moz-focus-inner, 720 740 input[type="submit"]::-moz-focus-inner { 721 border-width: 1px 0; 722 border-style: solid none; 723 border-color: transparent; 741 border: 0 none; 724 742 padding: 0; 743 } 744 745 .button.button-xl, 746 .button-group.button-xl .button { 747 font-size: 1rem; 748 height: 2.44141rem; 749 line-height: 1; 750 padding: 0 1.5rem; 725 751 } 726 752 727 753 .button.button-large, 728 754 .button-group.button-large .button, 729 .col-2 p.button, .col-13 p.button { 730 height: 30px; 731 line-height: 28px; 732 padding: 0 12px 2px; 755 .col-2 p.button, 756 .col-13 p.button { 757 height: 1.95313rem; 758 line-height: 1; 759 padding: 0 1rem; 733 760 } 734 761 … … 736 763 .block-content span.button, 737 764 .button-group.button-small .button { 738 height: 21px; 739 line-height: 20px; 740 padding: 0 8px 1px; 765 font-size: 0.64rem; 766 height: 1.25rem; 767 line-height: 1; 768 padding: 0 .5rem; 741 769 } 742 770 … … 751 779 } 752 780 753 .button:active { 781 a.button, 782 a.button-primary, 783 a.button-secondary { 784 line-height: 1.5625rem; 785 } 786 787 a.button.button-large, 788 .button-group.button-large a.button { 789 line-height: 1.95313rem; 790 } 791 792 a.button.button-xl, 793 .button-group.button-xl a.button { 794 line-height: 2.44141rem; 795 } 796 797 a.button.button-small, 798 .button-group.button-small a.button { 799 line-height: 1.25rem; 800 } 801 802 .button:active, 803 .button:focus { 754 804 outline: none; 755 805 } … … 759 809 } 760 810 761 /* 2.0 - Default Button Style */ 762 811 /* Style Reset buttons as simple text links */ 812 input[type="reset"], 813 input[type="reset"]:hover, 814 input[type="reset"]:active, 815 input[type="reset"]:focus { 816 background: none; 817 border: none; 818 -webkit-box-shadow: none; 819 box-shadow: none; 820 padding: 0 2px 1px; 821 width: auto; 822 } 823 824 /* ---------------------------------------------------------------------------- 825 2.0 - Default Button Style 826 ---------------------------------------------------------------------------- */ 763 827 .submit input, 764 828 input[type=button], 765 829 input[type=submit], 766 830 .button, 831 .button:visited, 767 832 .button-secondary { 768 background: #f3f3f3; 769 background-image: -webkit-gradient(linear, left top, left bottom, from(#fefefe), to(#f4f4f4)); 770 background-image: -webkit-linear-gradient(top, #fefefe, #f4f4f4); 771 background-image: -moz-linear-gradient(top, #fefefe, #f4f4f4); 772 background-image: -o-linear-gradient(top, #fefefe, #f4f4f4); 773 background-image: linear-gradient(to bottom, #fefefe, #f4f4f4); 774 border-color: #bbb; 775 color: #333; 776 text-shadow: 0 1px 0 #fff; 833 background: #f7f7f7; 834 border-color: #cccccc; 835 -webkit-box-shadow: 0 1px 0 #cccccc; 836 box-shadow: 0 1px 0 #cccccc; 837 color: #555; 838 vertical-align: top; 839 } 840 841 p .button { 842 vertical-align: baseline; 777 843 } 778 844 … … 789 855 .button:focus, 790 856 .button-secondary:focus { 791 background: #f3f3f3; 792 background-image: -webkit-gradient(linear, left top, left bottom, from(#fff), to(#f3f3f3)); 793 background-image: -webkit-linear-gradient(top, #fff, #f3f3f3); 794 background-image: -moz-linear-gradient(top, #fff, #f3f3f3); 795 background-image: -ms-linear-gradient(top, #fff, #f3f3f3); 796 background-image: -o-linear-gradient(top, #fff, #f3f3f3); 797 background-image: linear-gradient(to bottom, #fff, #f3f3f3); 857 background: #fafafa; 798 858 border-color: #999; 799 color: #2 22;859 color: #23282d; 800 860 } 801 861 … … 805 865 .button.focus, 806 866 .button:focus, 807 .button-secondary:focus { 808 -webkit-box-shadow: 1px 1px 1px rgba(0,0,0,.2); 809 box-shadow: 1px 1px 1px rgba(0,0,0,.2); 867 .button-secondary:focus, 868 .button-link:focus { 869 border-color: #5b9dd9; 870 -webkit-box-shadow: 0 0 3px rgba(0, 115, 170, 0.8); 871 box-shadow: 0 0 3px rgba(0, 115, 170, 0.8); 810 872 } 811 873 … … 819 881 .button-secondary:active { 820 882 background: #eee; 821 background-image: -webkit-gradient(linear, left top, left bottom, from(#f4f4f4), to(#fefefe));822 background-image: -webkit-linear-gradient(top, #f4f4f4, #fefefe);823 background-image: -moz-linear-gradient(top, #f4f4f4, #fefefe);824 background-image: -ms-linear-gradient(top, #f4f4f4, #fefefe);825 background-image: -o-linear-gradient(top, #f4f4f4, #fefefe);826 background-image: linear-gradient(to bottom, #f4f4f4, #fefefe);827 883 border-color: #999; 828 color: #333; 829 text-shadow: 0 -1px 0 #fff; 830 -webkit-box-shadow: inset 0 2px 5px -3px rgba( 0, 0, 0, 0.5 ); 831 box-shadow: inset 0 2px 5px -3px rgba( 0, 0, 0, 0.5 ); 884 -webkit-box-shadow: inset 0 2px 5px -3px rgba(0, 0, 0, 0.5); 885 box-shadow: inset 0 2px 5px -3px rgba(0, 0, 0, 0.5); 886 -webkit-transform: translateY(1px); 887 -ms-transform: translateY(1px); 888 transform: translateY(1px); 889 } 890 891 .button.active:focus { 892 border-color: #5b9dd9; 893 -webkit-box-shadow: inset 0 2px 5px -3px rgba(0, 0, 0, 0.5), 0 0 3px rgba(0, 115, 170, 0.8); 894 box-shadow: inset 0 2px 5px -3px rgba(0, 0, 0, 0.5), 0 0 3px rgba(0, 115, 170, 0.8); 832 895 } 833 896 … … 837 900 .button[disabled], 838 901 .button:disabled, 902 .button.disabled, 839 903 .button-secondary[disabled], 840 904 .button-secondary:disabled, 905 .button-secondary.disabled, 841 906 .button-disabled { 842 color: #aaa!important;907 background: #f7f7f7 !important; 843 908 border-color: #ddd !important; 844 background-image: -webkit-gradient(linear, left top, left bottom, from(#f9f9f9), to(#f4f4f4)) !important;845 background-image: -webkit-linear-gradient(top, #f9f9f9, #f4f4f4) !important;846 background-image: -moz-linear-gradient(top, #f9f9f9, #f4f4f4) !important;847 background-image: -ms-linear-gradient(top, #f9f9f9, #f4f4f4) !important;848 background-image: -o-linear-gradient(top, #f9f9f9, #f4f4f4) !important;849 background-image: linear-gradient(to bottom, #f9f9f9, #f4f4f4) !important;850 909 -webkit-box-shadow: none !important; 851 910 box-shadow: none !important; 911 color: #a0a5aa !important; 912 cursor: default; 852 913 text-shadow: 0 1px 0 #fff !important; 853 cursor: default; 854 } 855 856 /* 3.0 - Primary Button Style */ 857 914 -webkit-transform: none !important; 915 -ms-transform: none !important; 916 transform: none !important; 917 } 918 919 /* Buttons that look like links, for a cross of good semantics with the visual */ 920 .button-link { 921 background: none; 922 border: 0; 923 -webkit-border-radius: 0; 924 border-radius: 0; 925 -webkit-box-shadow: none; 926 box-shadow: none; 927 cursor: pointer; 928 margin: 0; 929 outline: none; 930 padding: 0; 931 } 932 933 .button-link:focus { 934 outline: #5b9dd9 solid 1px; 935 } 936 937 /* ---------------------------------------------------------------------------- 938 3.0 - Primary Button Style 939 ---------------------------------------------------------------------------- */ 858 940 .button-primary, 859 941 .download-button, 860 942 .button-primary:visited, 861 943 .download-button:visited { 862 background-color: #21759b; 863 background-image: -webkit-gradient(linear, left top, left bottom, from(#2a95c5), to(#21759b)); 864 background-image: -webkit-linear-gradient(top, #2a95c5, #21759b); 865 background-image: -moz-linear-gradient(top, #2a95c5, #21759b); 866 background-image: -ms-linear-gradient(top, #2a95c5, #21759b); 867 background-image: -o-linear-gradient(top, #2a95c5, #21759b); 868 background-image: linear-gradient(to bottom, #2a95c5, #21759b); 869 border-color: #21759b; 870 border-bottom-color: #1e6a8d; 871 -webkit-box-shadow: inset 0 1px 0 rgba(120,200,230,0.5); 872 box-shadow: inset 0 1px 0 rgba(120,200,230,0.5); 944 background: #0085ba; 945 border-color: #0073aa #006799 #006799; 946 -webkit-box-shadow: 0 1px 0 #006799; 947 box-shadow: 0 1px 0 #006799; 873 948 color: #fff; 874 949 text-decoration: none; 875 text-shadow: 0 1px 0 rgba(0,0,0,0.1);950 text-shadow: 0 -1px 1px #006799, 1px 0 1px #006799, 0 1px 1px #006799, -1px 0 1px #006799; 876 951 } 877 952 … … 884 959 .download-button.focus, 885 960 .download-button:focus { 886 background-color: #278ab7; 887 background-image: -webkit-gradient(linear, left top, left bottom, from(#2e9fd2), to(#21759b)); 888 background-image: -webkit-linear-gradient(top, #2e9fd2, #21759b); 889 background-image: -moz-linear-gradient(top, #2e9fd2, #21759b); 890 background-image: -ms-linear-gradient(top, #2e9fd2, #21759b); 891 background-image: -o-linear-gradient(top, #2e9fd2, #21759b); 892 background-image: linear-gradient(to bottom, #2e9fd2, #21759b); 893 border-color: #1b607f; 894 -webkit-box-shadow: inset 0 1px 0 rgba(120,200,230,0.6); 895 box-shadow: inset 0 1px 0 rgba(120,200,230,0.6); 961 background: #008ec2; 962 border-color: #006799; 896 963 color: #fff; 897 text-shadow: 0 -1px 0 rgba(0,0,0,0.3);898 964 } 899 965 … … 902 968 .download-button.focus, 903 969 .download-button:focus { 904 border-color: #0e3950; 905 -webkit-box-shadow: inset 0 1px 0 rgba(120,200,230,0.6), 1px 1px 2px rgba(0,0,0,0.4); 906 box-shadow: inset 0 1px 0 rgba(120,200,230,0.6), 1px 1px 2px rgba(0,0,0,0.4); 970 -webkit-box-shadow: 0 1px 0 #0073aa, 0 0 2px 1px #33b3db; 971 box-shadow: 0 1px 0 #0073aa, 0 0 2px 1px #33b3db; 907 972 } 908 973 … … 915 980 .download-button.active:focus, 916 981 .download-button:active { 917 background: #1b607f; 918 background-image: -webkit-gradient(linear, left top, left bottom, from(#21759b), to(#278ab7)); 919 background-image: -webkit-linear-gradient(top, #21759b, #278ab7); 920 background-image: -moz-linear-gradient(top, #21759b, #278ab7); 921 background-image: -ms-linear-gradient(top, #21759b, #278ab7); 922 background-image: -o-linear-gradient(top, #21759b, #278ab7); 923 background-image: linear-gradient(to bottom, #21759b, #278ab7); 924 border-color: #124560 #2382ae #2382ae #2382ae; 925 color: rgba(255,255,255,0.95); 926 -webkit-box-shadow: inset 0 1px 0 rgba(0,0,0,0.1); 927 box-shadow: inset 0 1px 0 rgba(0,0,0,0.1); 928 text-shadow: 0 1px 0 rgba(0,0,0,0.1); 982 background: #0073aa; 983 border-color: #006799; 984 -webkit-box-shadow: inset 0 2px 0 #006799; 985 box-shadow: inset 0 2px 0 #006799; 986 vertical-align: top; 929 987 } 930 988 … … 935 993 .download-button:disabled, 936 994 .download-button-disabled { 937 color: #94cde7 !important; 938 background: #298cba !important; 939 border-color: #1b607f !important; 995 background: #008ec2 !important; 996 border-color: #007cb2 !important; 940 997 -webkit-box-shadow: none !important; 941 998 box-shadow: none !important; 942 text-shadow: 0 -1px 0 rgba(0,0,0,0.1)!important;999 color: #66c6e4 !important; 943 1000 cursor: default; 944 } 1001 text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.1) !important; 1002 } 1003 1004 /* ---------------------------------------------------------------------------- 1005 4.0 - Button Groups 1006 ---------------------------------------------------------------------------- */ 1007 .button-group { 1008 display: inline-block; 1009 font-size: 0; 1010 position: relative; 1011 vertical-align: middle; 1012 white-space: nowrap; 1013 } 1014 1015 .button-group > .button { 1016 -webkit-border-radius: 0; 1017 border-radius: 0; 1018 display: inline-block; 1019 margin-right: -1px; 1020 z-index: 10; 1021 } 1022 1023 .button-group > .button-primary { 1024 z-index: 100; 1025 } 1026 1027 .button-group > .button:hover { 1028 z-index: 20; 1029 } 1030 1031 .button-group > .button:first-child { 1032 -webkit-border-radius: 3px 0 0 3px; 1033 border-radius: 3px 0 0 3px; 1034 } 1035 1036 .button-group > .button:last-child { 1037 -webkit-border-radius: 0 3px 3px 0; 1038 border-radius: 0 3px 3px 0; 1039 } 1040 1041 .button-group > .button:focus { 1042 position: relative; 1043 z-index: 1; 1044 } 1045 1046 /* ---------------------------------------------------------------------------- 1047 5.0 - Responsive Button Styles 1048 ---------------------------------------------------------------------------- */ 1049 @media screen and (max-width: 782px) { 1050 .button, 1051 .button.button-xl, 1052 .button.button-large, 1053 .button.button-small { 1054 font-size: 14px; 1055 height: auto; 1056 line-height: normal; 1057 margin-bottom: 4px; 1058 padding: 6px 14px; 1059 vertical-align: middle; 1060 } 1061 } 1062 945 1063 946 1064 /* */ … … 2231 2349 2232 2350 2233 /* 2351 /* 2234 2352 * Notifications 2235 2353 */
Note: See TracChangeset
for help on using the changeset viewer.