vertically align text and buttons

时间:2017-08-30 20:29:52

标签: html css

I wanted to center both the buttons and the text vertically, but the text as seen in the photo

enter image description here

is lower than the rest. If I remove the buttons, the text goes to center as it should, but if I leave the buttons, the text goes back down (How i wish it was).

enter image description here

D
let x = 1 || 0 === 0; // x === 1;

4 个答案:

答案 0 :(得分:0)

flexbox to the rescue.

Just add:

Desc_TypeD

I.E:

Global Instance Desc_TypeD : Desc TypeD :=
  { denotesInto := fun _ => Type
  ; denote :=
      match d with
      | ArrowD dL dR => ⟦ dL ⟧ -> ⟦ dR ⟧
      | ListD  dT    => list ⟦ dT ⟧
      | NatD         => nat
      end
   }.
fix

答案 1 :(得分:0)

Try to take your text in {"username":""something@something.com""...

And then you can edit it as you want to in your CSS.

A nice guide that I can suggest for centering the items with CSS ;

https://css-tricks.com/centering-css-complete-guide/

答案 2 :(得分:0)

One way that would work is to use flexbox:

OAuthAuthorizationServerOptions = new OAuthAuthorizationServerOptions
{
    AllowInsecureHttp = true,
    TokenEndpointPath = new PathString("/api/token"),
    AccessTokenExpireTimeSpan = TimeSpan.FromHours(2),
    Provider = new SimpleAuthorizationServerProvider(),
    RefreshTokenProvider = new ApplicationRefreshTokenProvider()
};

// Token Generation
app.UseOAuthAuthorizationServer(OAuthAuthorizationServerOptions);
app.UseOAuthBearerAuthentication(new OAuthBearerAuthenticationOptions
{
    Provider = new AppOAuthBearerAuthenticationProvider()
});
app.UseOAuthBearerAuthentication(new OAuthBearerAuthenticationOptions
{
    Provider = new AppOAuthBearerAuthenticationProvider()
});

答案 3 :(得分:0)

Try this out for your CSS:

$request->type

and add the following to a class associated with your buttons:

array(
    0 => array(id => value0, name => value0)
    1 => array(id => value1, name => value1)
    // more items
)